/[winpt]/trunk/Src/wptRegistry.cpp
ViewVC logotype

Diff of /trunk/Src/wptRegistry.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 76 by twoaday, Thu Nov 10 14:07:06 2005 UTC revision 80 by twoaday, Wed Nov 16 11:05:16 2005 UTC
# Line 122  int Line 122  int
122  regist_inst_winpt (int with_ext, int * created)  regist_inst_winpt (int with_ext, int * created)
123  {  {
124      HKEY reg;      HKEY reg;
125      char * p = NULL;      char *p = NULL;
126        char modpath[MAX_PATH+1];
127      int rc, i, id, n = 0;      int rc, i, id, n = 0;
128    
129      if( created )      if( created )
# Line 185  start: Line 186  start:
186      RegCloseKey( reg );      RegCloseKey( reg );
187      if( n )      if( n )
188          set_reg_entry( HKEY_CURRENT_USER, WINPT_REG, "Extensions", "1" );          set_reg_entry( HKEY_CURRENT_USER, WINPT_REG, "Extensions", "1" );
189        if ((n=GetModuleFileName (NULL, modpath, MAX_PATH-1)) > 0) {
190            while (n-- > 0) {
191                if (modpath[n] == '\\') {
192                    modpath[n] = 0;
193                    break;
194                }
195            }
196            set_reg_entry (HKEY_CURRENT_USER, WINPT_REG,
197                           "Install Directory", modpath);
198        }
199        
200      return 0;      return 0;
201  } /* regist_inst_winpt */  }
202    
203    
204  /* Create a new filetype in the W32 registry.  /* Create a new filetype in the W32 registry.

Legend:
Removed from v.76  
changed lines
  Added in v.80

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26