- Window dumw;
- int dumi;
- unsigned int dumu;
-
- XQueryPointer( GDK_DISPLAY(),GDK_ROOT_WINDOW(),
- &dumw,&dumw,x,y,&dumi,&dumi,&dumu );
-}
-
-bool wxColourDisplay(void)
-{
- return TRUE;
-}
-
-int wxDisplayDepth(void)
-{
- wxFAIL_MSG( "wxDisplayDepth always returns 8" );
- return 8;
-}
-
-//------------------------------------------------------------------------
-// user and home routines
-//------------------------------------------------------------------------
-
-const char* wxGetHomeDir( wxString *home )
-{
- *home = wxGetUserHome( wxString() );
- if (home->IsNull()) *home = "/";
- return *home;
-}
-
-char *wxGetUserHome( const wxString &user )
-{
- struct passwd *who = (struct passwd *) NULL;
-
- if (user.IsNull() || (user== ""))
- {
- register char *ptr;
-
- if ((ptr = getenv("HOME")) != NULL)
- {
- return ptr;
- }
- if ((ptr = getenv("USER")) != NULL || (ptr = getenv("LOGNAME")) != NULL)
- {
- who = getpwnam(ptr);
- }
- // We now make sure the the user exists!
- if (who == NULL)
- {
- who = getpwuid(getuid());
- }
- }
- else
- {
- who = getpwnam (user);
- }
-
- return who ? who->pw_dir : (char*)NULL;