Changeset 40
- Timestamp:
- 05/13/07 17:23:30 (2 years ago)
- Files:
-
- branches/bughunt/minwin/listbox.d (modified) (1 diff)
- branches/bughunt/minwin/window.d (modified) (2 diffs)
- branches/bughunt/samples/notepad.d (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/bughunt/minwin/listbox.d
r33 r40 28 28 class ListBox : WindowChild { 29 29 30 this(Component parent, char[][] text, char[] name = "") {30 this(Component parent, char[][] text, bool vscroll = true, bool hscroll = true, char[] name = "") { 31 31 PeerForAdd parentp = parent.getPeerForAdd(); 32 32 this.name = name; branches/bughunt/minwin/window.d
r38 r40 189 189 if (backgroundPeer && ownsBackgroundPeer) 190 190 DeleteObject(backgroundPeer); 191 backgroundPeer = null; 191 backgroundPeer = null; 192 192 ownsBackgroundPeer = false; 193 193 //delete WindowList[this]; // remove global reference … … 690 690 GdkEventMask.GDK_BUTTON_PRESS_MASK | 691 691 GdkEventMask.GDK_BUTTON_RELEASE_MASK); 692 // changed the old 0 to G_CONNECT_AFTER as it was causing strange problems 692 693 g_signal_connect_data(peer,"destroy", 693 694 cast(GCallback)&mw_destroy_callback, 694 695 cast(gpointer)this, 695 null, cast(GConnectFlags)0);696 null,GConnectFlags.G_CONNECT_AFTER);//null,cast(GConnectFlags)0); 696 697 g_signal_connect_data(peer,"delete-event", 697 698 cast(GCallback)&mw_close_callback, 698 699 cast(gpointer)this, 699 null, cast(GConnectFlags)0);700 null,GConnectFlags.G_CONNECT_AFTER);//null,cast(GConnectFlags)0); 700 701 g_signal_connect_data(peer,"configure-event", 701 702 cast(GCallback)&mw_notify_callback, 702 703 cast(gpointer)this, 703 null, cast(GConnectFlags)0);704 null,GConnectFlags.G_CONNECT_AFTER);//null,cast(GConnectFlags)0); 704 705 setWindowPeer(this,peer,OWNS_PEER); 705 706 WindowList[this] = this; // prevent garbage collection branches/bughunt/samples/notepad.d
r39 r40 30 30 31 31 MultiLineText text = new MultiLineText(win); 32 text.userPreferredSize( 200,200);32 text.userPreferredSize(win.width, win.height); 33 33 34 34 win.commandDelegate ~= (Component c, int cmd) { … … 48 48 }; 49 49 50 //win.windowDelegate ~= (Component c, WindowEvent* e) {}; 50 win.windowDelegate ~= (Component c, WindowEvent* e) { 51 text.userPreferredSize(c.width,c.height); 52 win.childLayoutDirty = true; 53 }; 51 54 52 55 win.pack();
