Diff for /np2/macosx/toolwin.cpp between versions 1.8 and 1.9

version 1.8, 2003/11/08 17:54:26 version 1.9, 2003/11/11 16:33:50
Line 165  static PicHandle skinload(const char *pa Line 165  static PicHandle skinload(const char *pa
                         return(ret);                          return(ret);
                 }                  }
         }          }
         return(getBMPfromResource("np2tool", bounds));          return(getBMPfromResource("np2tool", bounds, CFSTR("bmp")));
 }  }
   
 // ----  // ----
Line 533  static pascal OSStatus cfWinproc(EventHa Line 533  static pascal OSStatus cfWinproc(EventHa
                 break;                  break;
         }          }
     }      }
       else if (GetEventClass(event)==kEventClassKeyboard && GetEventKind(event)==kEventRawKeyDown) {
           UInt32 modif;
           GetEventParameter (event, kEventParamKeyModifiers, typeUInt32, NULL, sizeof(UInt32), NULL, &modif);
           if (modif & cmdKey) {
               EventRecord eve;
               ConvertEventRefToEventRecord( event,&eve );
               recieveCommand(MenuEvent(&eve));
           }
       }
   
         (void)myHandler;          (void)myHandler;
     return err;      return err;
Line 628  static WindowRef makeNibWindow (IBNibRef Line 637  static WindowRef makeNibWindow (IBNibRef
     if (err == noErr) {      if (err == noErr) {
         InstallStandardEventHandler(GetWindowEventTarget(win));          InstallStandardEventHandler(GetWindowEventTarget(win));
         EventTypeSpec   list[]={           EventTypeSpec   list[]={ 
             { kEventClassCommand, kEventCommandProcess },              { kEventClassCommand,       kEventCommandProcess },
             { kEventClassWindow, kEventWindowClose },               { kEventClassWindow,        kEventWindowClose }, 
             { kEventClassWindow, kEventWindowShown },               { kEventClassWindow,        kEventWindowShown }, 
             { kEventClassWindow, kEventWindowDrawContent },               { kEventClassWindow,        kEventWindowDrawContent }, 
             { kEventClassWindow, kEventWindowFocusAcquired },               { kEventClassWindow,        kEventWindowFocusAcquired }, 
               { kEventClassKeyboard,      kEventRawKeyDown},
         };          };
         EventHandlerRef ref;          EventHandlerRef ref;
         InstallWindowEventHandler (win, NewEventHandlerUPP(cfWinproc), GetEventTypeCount(list), list, (void *)win, &ref);          InstallWindowEventHandler (win, NewEventHandlerUPP(cfWinproc), GetEventTypeCount(list), list, (void *)win, &ref);
Line 671  const char *file[SKINMRU_MAX]; Line 681  const char *file[SKINMRU_MAX];
         AppendMenu(ret, "\p-");          AppendMenu(ret, "\p-");
   
         base = np2tool.skin;          base = np2tool.skin;
         AppendMenuItemTextWithCFString(ret, CFCopyLocalizedString(CFSTR("Base Skin"),"Base Skin"), kMenuItemAttrIconDisabled, NULL,NULL);          AppendMenuItemTextWithCFString(ret, CFCopyLocalizedString(CFSTR("<Base Skin>"),"Base Skin"), kMenuItemAttrIconDisabled, NULL,NULL);
         if (base[0] == '\0') {          if (base[0] == '\0') {
         DisableMenuItem(ret, 3);          DisableMenuItem(ret, 3);
     }      }
Line 845  void toolwin_open(void) { Line 855  void toolwin_open(void) {
     }      }
 #endif  #endif
   
       np2oscfg.toolwin = 1;
         return;          return;
   
 twope_err2:  twope_err2:
Line 872  void toolwin_close(void) { Line 883  void toolwin_close(void) {
         toolwindestroy();          toolwindestroy();
         DisposeWindow(toolwin.hwnd);          DisposeWindow(toolwin.hwnd);
         toolwin.hwnd = NULL;          toolwin.hwnd = NULL;
           np2oscfg.toolwin = 0;
     }      }
 }  }
   

Removed from v.1.8  
changed lines
  Added in v.1.9


RetroPC.NET-CVS <cvs@retropc.net>