Hi everyone, and also Ivan because it's about gui.

Here is my first patch to gui to bring it an Applicationfolder icon. NSApplicationFolder already exists in base so I didn't need to add it.

I've added few lines to NSWorkspace.m to display an icon on all Application folder. And made an icon from the defaultFolder icon and and the default unknownApplication icon.

See the two files attached.

Can you please review them ? And see if is possible to get rid of the sysAppDir variable ?

Cheers,
Bertrand Dekoninck

PS :
Who will I have to ask for a copyright assignment in the future ? Greg ?
Index: Images/GNUmakefile
===================================================================
--- Images/GNUmakefile	(révision 39565)
+++ Images/GNUmakefile	(copie de travail)
@@ -49,6 +49,7 @@
  common_3DArrowRight.tiff \
  common_3DArrowRightH.tiff \
  common_3DArrowUp.tiff \
+ common_ApplicationFolder.tiff \
  common_ArrowDown.tiff \
  common_ArrowDownH.tiff \
  common_ArrowLeft.tiff \
Index: Source/NSWorkspace.m
===================================================================
--- Source/NSWorkspace.m	(révision 39565)
+++ Source/NSWorkspace.m	(copie de travail)
@@ -671,6 +671,7 @@
   NSArray *documentDir;
   NSArray *libraryDirs;
   NSArray *sysAppDir;
+  NSArray *appDirs;
   NSArray *downloadDir;
   NSArray *desktopDir;
   NSArray *imgDir;
@@ -726,6 +727,8 @@
     NSAllDomainsMask, YES);
   sysAppDir = NSSearchPathForDirectoriesInDomains(NSApplicationDirectory,
     NSSystemDomainMask, YES);
+  appDirs = NSSearchPathForDirectoriesInDomains(NSApplicationDirectory,
+    NSAllDomainsMask, YES);
   imgDir = NSSearchPathForDirectoriesInDomains(NSPicturesDirectory,
     NSUserDomainMask, YES);
   musicDir = NSSearchPathForDirectoriesInDomains(NSMusicDirectory,
@@ -756,6 +759,11 @@
       [folderPathIconDict setObject: @"LibraryFolder"
 	forKey: [libraryDirs objectAtIndex: i]];
     }
+  for (i = 0; i < [appDirs count]; i++)
+    {
+      [folderPathIconDict setObject: @"ApplicationFolder"
+	forKey: [appDirs objectAtIndex: i]];
+    }
   for (i = 0; i < [documentDir count]; i++)
     {
       [folderPathIconDict setObject: @"DocsFolder"
_______________________________________________
Gnustep-dev mailing list
Gnustep-dev@gnu.org
https://lists.gnu.org/mailman/listinfo/gnustep-dev

Reply via email to