Patch level : 2.0 476
Files correlati : xvagadll.dll ba1.exe Ricompilazione Demo : [ ] Commento : Corretto calcolo spazio libero su disco git-svn-id: svn://10.65.10.50/trunk@11181 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
8412404661
commit
568f53bef1
@ -1232,6 +1232,9 @@ void xvt_app_process_pending_events(void)
|
|||||||
{
|
{
|
||||||
if (wxTheApp != NULL)
|
if (wxTheApp != NULL)
|
||||||
{
|
{
|
||||||
|
#ifdef WIN32
|
||||||
|
::WaitMessage();
|
||||||
|
#endif
|
||||||
for (int m = 0; m < 4 && wxTheApp->Pending(); m++)
|
for (int m = 0; m < 4 && wxTheApp->Pending(); m++)
|
||||||
wxTheApp->Dispatch();
|
wxTheApp->Dispatch();
|
||||||
}
|
}
|
||||||
@ -2458,7 +2461,14 @@ BOOLEAN xvt_fsys_parse_pathname(const char *mbs, char *volname, char *dirname, c
|
|||||||
{
|
{
|
||||||
wxString volume, path, file, ext;
|
wxString volume, path, file, ext;
|
||||||
wxFileName::SplitPath(mbs, &volume, &path, &file, &ext);
|
wxFileName::SplitPath(mbs, &volume, &path, &file, &ext);
|
||||||
if (volname) strcpy(volname, volume);
|
if (volname)
|
||||||
|
{
|
||||||
|
strcpy(volname, volume);
|
||||||
|
#ifdef WIN32
|
||||||
|
if (volname[0] != '\0' && volname[1] == '\0')
|
||||||
|
strcat(volname, ":");
|
||||||
|
#endif
|
||||||
|
}
|
||||||
if (dirname) strcpy(dirname, path);
|
if (dirname) strcpy(dirname, path);
|
||||||
if (leafroot) strcpy(leafroot, file);
|
if (leafroot) strcpy(leafroot, file);
|
||||||
if (leafext) strcpy(leafext, ext);
|
if (leafext) strcpy(leafext, ext);
|
||||||
@ -3534,8 +3544,8 @@ long xvt_sys_execute(const char* cmdline, BOOLEAN sync, BOOLEAN iconizetask)
|
|||||||
long xvt_sys_execute_in_window(const char* cmdline, WINDOW win)
|
long xvt_sys_execute_in_window(const char* cmdline, WINDOW win)
|
||||||
{
|
{
|
||||||
long inst = xvt_sys_execute(cmdline, FALSE, FALSE);
|
long inst = xvt_sys_execute(cmdline, FALSE, FALSE);
|
||||||
#ifdef WIN32
|
|
||||||
if (inst > 0)
|
if (inst > 0)
|
||||||
|
#ifdef WIN32
|
||||||
OsWin32_PlaceProcessInWindow(inst, "", xvt_vobj_get_attr(ATTR_NATIVE_WINDOW, win));
|
OsWin32_PlaceProcessInWindow(inst, "", xvt_vobj_get_attr(ATTR_NATIVE_WINDOW, win));
|
||||||
#else
|
#else
|
||||||
OsLinux_PlaceProcessInWindow(inst, "", xvt_vobj_get_attr(ATTR_NATIVE_WINDOW, win));
|
OsLinux_PlaceProcessInWindow(inst, "", xvt_vobj_get_attr(ATTR_NATIVE_WINDOW, win));
|
||||||
@ -3734,27 +3744,39 @@ void xvt_sys_searchenv(const char * filename, const char * varname, char * pathn
|
|||||||
const char * value = getenv(varname);
|
const char * value = getenv(varname);
|
||||||
if (value)
|
if (value)
|
||||||
{
|
{
|
||||||
char path_list[4096];
|
/*
|
||||||
|
char path_list[4096];
|
||||||
const char * s = path_list;
|
const char * s = path_list;
|
||||||
|
|
||||||
strcpy(path_list, value);
|
strcpy(path_list, value);
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
char * s1 = strchr(s, ';');
|
char* s1 = strchr(s, ';');
|
||||||
|
|
||||||
if (s1 != NULL)
|
if (s1 != NULL)
|
||||||
*s1 = '\0';
|
*s1 = '\0';
|
||||||
|
|
||||||
char fname[256];
|
char fname[256];
|
||||||
|
|
||||||
strcpy(fname, s);
|
strcpy(fname, s);
|
||||||
strcat(fname, filename);
|
strcat(fname, filename);
|
||||||
if (wxFileExists(fname))
|
if (wxFileExists(fname))
|
||||||
strcpy(pathname, s);
|
strcpy(pathname, s); // Secondo Guy manca break
|
||||||
if (s1 != NULL)
|
if (s1 != NULL)
|
||||||
s = s1 + 1;
|
s = s1 + 1;
|
||||||
} while (s);
|
} while (s); // Secondo Guy e' sempre != NULL
|
||||||
|
*/
|
||||||
|
char path_list[4096];
|
||||||
|
strcpy(path_list, value);
|
||||||
|
for (const char* s = path_list; *s; )
|
||||||
|
{
|
||||||
|
char* s1 = strchr(s, ';');
|
||||||
|
if (s1 != NULL)
|
||||||
|
*s1 = '\0';
|
||||||
|
xvt_fsys_build_pathname(pathname, NULL, s, filename, NULL, NULL);
|
||||||
|
if (xvt_fsys_file_exists(pathname))
|
||||||
|
break;
|
||||||
|
if (s1 != NULL)
|
||||||
|
s = s1 + 1;
|
||||||
|
else
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
*pathname = '\0';
|
*pathname = '\0';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user