handle GetDateFormat) failures

(idea by Thomas Weidenmueller)

svn path=/trunk/; revision=9222
This commit is contained in:
Martin Fuchs
2004-04-25 20:22:04 +00:00
parent c038032038
commit 375cb8f522
3 changed files with 8 additions and 4 deletions
@@ -1,3 +1,4 @@
- rewrite autostart code and include all possible autostart locations
- read "DESCRIPT.ION" files to display file descriptions
- context menus for quick launch bar
- detect display mode changes and adjust desktop bar size
@@ -536,7 +536,7 @@ String ShellBrowserChild::jump_to_int(LPCTSTR url)
if (jump_to_pidl(ShellPath(dir)))
return FmtString(TEXT("file://%s"), (LPCTSTR)dir);
}
return String();
}
@@ -564,7 +564,8 @@ bool ShellBrowserChild::jump_to_pidl(LPCITEMIDLIST pidl)
Entry* found = entry->find_entry(p);
p = entry->get_next_path_component(p);
hitem = select_entry(hitem, found);
if (found)
hitem = select_entry(hitem, found);
entry = found;
}
@@ -1172,9 +1172,11 @@ int ClockWindow::Notify(int id, NMHDR* pnmh)
TCHAR buffer[64];
GetLocalTime(&systime);
GetDateFormat(LOCALE_USER_DEFAULT, DATE_LONGDATE, &systime, NULL, buffer, 64);
_tcscpy(pdi->szText, buffer);
if (GetDateFormat(LOCALE_USER_DEFAULT, DATE_LONGDATE, &systime, NULL, buffer, 64))
_tcscpy(pdi->szText, buffer);
else
pdi->szText[0] = '\0';
}
return 0;