]> code.citadel.org Git - citadel.git/commitdiff
fixes for wxMotif
authorNathan Bryant <loanshark@uncensored.citadel.org>
Tue, 6 Apr 1999 02:19:03 +0000 (02:19 +0000)
committerNathan Bryant <loanshark@uncensored.citadel.org>
Tue, 6 Apr 1999 02:19:03 +0000 (02:19 +0000)
daphne/main.cpp
daphne/roomtree.cpp

index dd956fc3f35662c6dfdffea36b54111600e01d78..756018cba3c9b2380c2457c6dbfbbde468704535 100644 (file)
@@ -9,6 +9,13 @@
 
 #include "includes.hpp"
 
+#ifdef __WXMOTIF__
+#include "bitmaps/globe.xpm"
+#include "bitmaps/mail.xpm"
+#include "bitmaps/who.xpm"
+#include "bitmaps/chat.xpm"
+#endif
+
 
 // Globals
 wxMDIParentFrame *BigMDI;
@@ -206,15 +213,22 @@ void MyFrame::InitToolBar(wxToolBar* toolBar) {
 // told how big the toolbar icons are going to be, otherwise it defaults to
 // 16x16.  Strangely, wxToolBar::SetToolBitmapSize() doesn't seem to be
 // available at all in wxGTK, hence the ifdef...
-#ifdef __WXMSW__
+#ifndef __WXGTK__
        toolBar->SetToolBitmapSize(wxSize(32, 32));
 #endif
 
         // Set up the toolbar icons (BMP is available on both GTK and MSW) 
+#ifndef __WXMOTIF__
        bitmaps[0] = new wxBitmap("bitmaps/globe.bmp",  wxBITMAP_TYPE_BMP);
        bitmaps[1] = new wxBitmap("bitmaps/mail.bmp",   wxBITMAP_TYPE_BMP);
        bitmaps[2] = new wxBitmap("bitmaps/who.bmp",    wxBITMAP_TYPE_BMP);
        bitmaps[3] = new wxBitmap("bitmaps/chat.bmp",   wxBITMAP_TYPE_BMP);
+#else
+       bitmaps[0] = new wxBitmap(globe_xpm);
+       bitmaps[1] = new wxBitmap(mail_xpm);
+       bitmaps[2] = new wxBitmap(who_xpm);
+       bitmaps[3] = new wxBitmap(chat_xpm);
+#endif
 
        toolBar->AddTool(MENU_CONNECT,
                        *bitmaps[0],
index 61c1fc4190b8b75cf57de729aed5cb74a8cb13da..a08c42ca9546304dde04f1485b451c2061c33fbe 100644 (file)
@@ -1,5 +1,13 @@
 #include "includes.hpp"
 
+#ifdef __WXMOTIF__
+#include "bitmaps/root.xpm"
+#include "bitmaps/floor.xpm"
+#include "bitmaps/newroom.xpm"
+#include "bitmaps/oldroom.xpm"
+#include "bitmaps/mailroom.xpm"
+#endif
+
 
 
 class RoomItem : public wxTreeItemData {
@@ -47,11 +55,19 @@ RoomTree::RoomTree(wxMDIParentFrame *parent, CitClient *sock)
 
 void RoomTree::InitTreeIcons(void) {
        TreeIcons = new wxImageList(16, 16);
+#ifdef __WXMOTIF__
+       TreeIcons->Add(*new wxBitmap(root_xpm));
+       TreeIcons->Add(*new wxBitmap(floor_xpm));
+       TreeIcons->Add(*new wxBitmap(newroom_xpm));
+       TreeIcons->Add(*new wxBitmap(oldroom_xpm));
+       TreeIcons->Add(*new wxBitmap(mailroom_xpm));
+#else
        TreeIcons->Add(*new wxBitmap("bitmaps/root.bmp", wxBITMAP_TYPE_BMP));
        TreeIcons->Add(*new wxBitmap("bitmaps/floor.bmp", wxBITMAP_TYPE_BMP));
        TreeIcons->Add(*new wxBitmap("bitmaps/newroom.bmp", wxBITMAP_TYPE_BMP));
        TreeIcons->Add(*new wxBitmap("bitmaps/oldroom.bmp", wxBITMAP_TYPE_BMP));
        TreeIcons->Add(*new wxBitmap("bitmaps/mailroom.bmp", wxBITMAP_TYPE_BMP));
+#endif
        SetImageList(TreeIcons);
 }