Changeset dc7a309ca203…
Parent 0009b0c410e1…
by
Changes to 3 files · Browse files at dc7a309ca203 Showing diff from parent 0009b0c410e1 Diff from another changeset...
@@ -112,7 +112,7 @@ MenuDescriptionMap MenuDescMap;
MenuIdCmdMap MenuIdMap;
-void AddMenuList(int idCmd, std::string name)
+void AddMenuList(int idCmd, std::string const& name)
{
TDEBUG_TRACE("AddMenuList: idCmd = " << idCmd << " name = " << name);
MenuIdMap[idCmd] = MenuDescMap[name];
@@ -135,7 +135,7 @@}
void InsertMenuItemWithIcon(HMENU hMenu, int indexMenu, int idCmd,
- std::string menuText, std::string iconName)
+ std::string const& menuText, std::string const& iconName)
{
MENUITEMINFO mi;
mi.cbSize = sizeof(mi);
@@ -160,7 +160,7 @@}
void InsertSubMenuItemWithIcon(HMENU hMenu, HMENU hSubMenu, int indexMenu, int idCmd,
- std::string menuText, std::string iconName)
+ std::string const& menuText, std::string const& iconName)
{
MENUITEMINFO mi;
mi.cbSize = sizeof(mi);
@@ -185,7 +185,7 @@ InsertMenuItem(hMenu, indexMenu, TRUE, &mi);
}
-void InsertMenuItemByName(HMENU hMenu, std::string name, int indexMenu,
+void InsertMenuItemByName(HMENU hMenu, std::string const& name, int indexMenu,
int idCmd, int idCmdFirst)
{
TDEBUG_TRACE("InsertMenuItemByName: name = " << name);
|
@@ -42,10 +42,9 @@ };
-BOOL hasHgDir(std::string path)
+BOOL hasHgDir(std::string const& path)
{
- path += "\\.hg";
- return PathIsDirectory(path.c_str());
+ return PathIsDirectory((path + "\\.hg").c_str());
}
|
@@ -109,7 +109,7 @@
// Cuts the first token off a delimited list
-std::string CutFirstToken(std::string& sList, const std::string sDelimiter)
+std::string CutFirstToken(std::string& sList, const std::string& sDelimiter)
{
std::string::size_type p = sList.find(sDelimiter);
std::string sResult;
|
Loading...