Changeset 30614
- Timestamp:
- 02/28/09 14:52:42 (4 years ago)
- Location:
- lang/cplusplus/i3/trunk
- Files:
-
- 7 modified
-
am/i3.am (modified) (1 diff)
-
src/CompletionWindow.cpp (modified) (1 diff)
-
src/CompletionWindow.h (modified) (1 diff)
-
src/gui-gnustep/CompletionWindowPlatform.cpp (modified) (4 diffs)
-
src/gui-gnustep/InputWindowPlatform.cpp (modified) (2 diffs)
-
src/gui-gnustep/InputWindowPlatform.h (modified) (1 diff)
-
src/mol/include/mol/gui-gnustep/GuiModule.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
lang/cplusplus/i3/trunk/am/i3.am
r30470 r30614 13 13 -funit-at-a-time \ 14 14 ${WARNING_OPTIONS} \ 15 -DLOCALEDIR=\"${localedir}\" 16 15 -DLOCALEDIR=\"${localedir}\" 16 #-fno-rtti 17 17 #DEFS += -DLOCALEDIR=\"${localedir}\" 18 18 -
lang/cplusplus/i3/trunk/src/CompletionWindow.cpp
r30427 r30614 20 20 } 21 21 22 void CompletionWindow::run()23 {24 22 } 25 } -
lang/cplusplus/i3/trunk/src/CompletionWindow.h
r30427 r30614 18 18 ~CompletionWindow(); 19 19 20 void run();21 22 20 template <typename T> 23 21 void execute(T& event); -
lang/cplusplus/i3/trunk/src/gui-gnustep/CompletionWindowPlatform.cpp
r30600 r30614 4 4 #include "Mediator.h" 5 5 6 /** 7 * 8 */ 6 typedef i3::CompletionWindowPlatform<i3::CompletionWindow> ParentType; 7 #define WindowType CompletionWindowObjC 8 #include <mol/gui-gnustep/GuiModuleObjC.h> 9 9 10 10 using namespace mol; … … 26 26 void CompletionWindowPlatform<CompletionWindow>::createUI() 27 27 { 28 29 28 NSRect rect = NSMakeRect (100, 100, 200, 200); 30 29 unsigned int styleMask = NSTitledWindowMask 31 30 | NSMiniaturizableWindowMask; 32 31 33 34 window = [NSWindow alloc]; 32 window = [[WindowType alloc] setParent: this]; 35 33 window = [window initWithContentRect: rect 36 34 styleMask: styleMask … … 38 36 defer: NO]; 39 37 [window setTitle: 40 [[NSString alloc] initWithUTF8String:_("Hello Completion")]];38 [[NSString alloc] initWithUTF8String:_("Hello compl")]]; 41 39 [window makeKeyAndOrderFront: nil]; 42 43 40 } 44 41 … … 51 48 52 49 } 50 51 #include <mol/gui-gnustep/GuiModuleObjCImpl.h> -
lang/cplusplus/i3/trunk/src/gui-gnustep/InputWindowPlatform.cpp
r30600 r30614 3 3 #include "InputWindowPlatform.h" 4 4 #include "InputWindow.h" 5 6 typedef i3::InputWindowPlatform<i3::InputWindow> ParentType; 7 #define WindowType InputWindowObjC 8 #include <mol/gui-gnustep/GuiModuleObjC.h> 9 10 namespace i3 11 { 12 using namespace mol; 13 14 template <> 15 InputWindowPlatform<InputWindow>::InputWindowPlatform(Mediator& mediator) : mediator(mediator) 16 { 17 } 18 19 template <> 20 InputWindowPlatform<InputWindow>::~InputWindowPlatform() 21 { 22 } 23 24 template <> 25 void InputWindowPlatform<InputWindow>::createUI() 26 { 27 /* 28 NSRect rect = NSMakeRect (100, 100, 200, 200); 29 unsigned int styleMask = NSTitledWindowMask 30 | NSMiniaturizableWindowMask; 31 32 window = [[WindowType alloc] setParent: this]; 33 window = [window initWithContentRect: rect 34 styleMask: styleMask 35 backing: NSBackingStoreBuffered 36 defer: NO]; 37 [window setTitle: 38 [[NSString alloc] initWithUTF8String:_("Hello Input")]]; 39 [window makeKeyAndOrderFront: nil]; 40 */ 41 } 42 43 template <> 44 void InputWindowPlatform<InputWindow>::objctest() 45 { 46 MessageBox(NULL, _T("foo"), _T("bar"), MB_OK); 47 } 48 49 template <> 50 void InputWindowPlatform<InputWindow>::destroy() 51 { 52 } 53 54 template <> 55 void InputWindowPlatform<InputWindow>::run() 56 { 57 createUI(); 58 loop(); 59 } 60 } 61 62 #include <mol/gui-gnustep/GuiModuleObjCImpl.h> 63 5 64 /* 6 65 @interface MyDelegate : NSObject … … 47 106 @end 48 107 */ 49 namespace i350 {51 using namespace mol;52 108 53 54 template <>55 InputWindowPlatform<InputWindow>::InputWindowPlatform(Mediator& mediator) : mediator(mediator)56 {57 }58 59 template <>60 InputWindowPlatform<InputWindow>::~InputWindowPlatform()61 {62 }63 64 template <>65 void InputWindowPlatform<InputWindow>::createUI()66 {67 NSRect rect = NSMakeRect (100, 100, 200, 200);68 unsigned int styleMask = NSTitledWindowMask69 | NSMiniaturizableWindowMask;70 71 72 window = [NSWindow alloc];73 window = [window initWithContentRect: rect74 styleMask: styleMask75 backing: NSBackingStoreBuffered76 defer: NO];77 [window setTitle:78 [[NSString alloc] initWithUTF8String:_("Hello Input")]];79 [window makeKeyAndOrderFront: nil];80 }81 82 template <>83 void InputWindowPlatform<InputWindow>::destroy()84 {85 }86 87 template <>88 void InputWindowPlatform<InputWindow>::run()89 {90 createUI();91 loop();92 }93 } -
lang/cplusplus/i3/trunk/src/gui-gnustep/InputWindowPlatform.h
r30428 r30614 19 19 void createUI(); 20 20 void destroy(); 21 void objctest(); 21 22 Mediator& mediator; 22 23 -
lang/cplusplus/i3/trunk/src/mol/include/mol/gui-gnustep/GuiModule.h
r30600 r30614 147 147 { 148 148 [NSApp run]; 149 return; 150 /* 149 151 while (!breakLoopRequest.load()) 150 152 { … … 162 164 } 163 165 breakLoopRequest.store(false); 166 */ 164 167 } 165 168 };
![(please configure the [header_logo] section in trac.ini)](/share/chrome/site/your_project_logo.png)