Changeset 1498 for trunk/gsinstaller/gsProgman.cpp
- Timestamp:
- 2000-09-05T03:30:48+12:00 (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsinstaller/gsProgman.cpp
r1475 r1498 87 87 88 88 void gsProgramManager::logAction(string actionName, string group) 89 { manager->writeString(actionName); 90 manager->writeSeparator(); 91 manager->writeString(group); 92 manager->writeString("\n"); 89 { unInstallCommand command(actionName); 90 command.addParameter(group); 91 manager->storeCommand(command); 93 92 } 94 93 95 94 void gsProgramManager::logAction(string actionName, string group, string item, string parameter) 96 { manager->writeString(actionName); 97 manager->writeSeparator(); 98 manager->writeString(group); 99 manager->writeSeparator(); 100 manager->writeString(item); 101 manager->writeSeparator(); 102 manager->writeString(parameter); 103 manager->writeString("\n"); 95 { unInstallCommand command(actionName); 96 command.addParameter(group); 97 command.addParameter(item); 98 command.addParameter(parameter); 99 manager->storeCommand(command); 104 100 } 105 101 … … 109 105 return true; 110 106 } 111 else if (actionName == "ProgManAddI con")107 else if (actionName == "ProgManAddItem") 112 108 { this->removeIcon(params[0], params[1]); 113 109 return true; … … 211 207 fullPath = new FilePath(4, buffer, groupName.c_str(), iconName.c_str(), ".lnk"); 212 208 209 // check if the shortcut already exists then don't create this again 210 if (fullPath->exists()) 211 { delete fullPath; 212 return true; 213 } 214 213 215 // Get a pointer to the IShellLink interface. 214 216 hres = CoCreateInstance(CLSID_ShellLink, NULL, … … 241 243 psl->Release(); 242 244 } 245 delete fullPath; 243 246 } 244 247 else … … 317 320 } 318 321 322 // get path of folder from shell 319 323 SHGetPathFromIDList(pidl, buffer); 320 fullPath = new FilePath(4, buffer, groupName.c_str(), iconName.c_str(), "!.lnk"); 321 322 // TODO: delete file 324 325 // delete file 326 fullPath = new FilePath(4, buffer, groupName.c_str(), iconName.c_str(), "!.lnk"); 327 if (!DeleteFile(fullPath->cString())) 328 { reply = false; 329 } 330 delete fullPath; 323 331 } 324 332 else
Note:
See TracChangeset
for help on using the changeset viewer.