r113 - in trunk/src/target/OM-2007: artwork/themes/openmoko-standard/gtk-2.0 examples examples/openmoko-paned-demo libraries/mokoui panel-plugins
mickey at gta01.hmw-consulting.de
mickey at gta01.hmw-consulting.de
Mon Oct 23 17:11:36 CEST 2006
Author: mickey
Date: 2006-10-23 15:11:34 +0000 (Mon, 23 Oct 2006)
New Revision: 113
Added:
trunk/src/target/OM-2007/examples/examples.pro
trunk/src/target/OM-2007/libraries/mokoui/moko-toolbox.c
trunk/src/target/OM-2007/libraries/mokoui/moko-toolbox.h
Removed:
trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.c
trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.h
Modified:
trunk/src/target/OM-2007/artwork/themes/openmoko-standard/gtk-2.0/gtkrc
trunk/src/target/OM-2007/examples/openmoko-paned-demo/demo-main.c
trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.c
trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.h
trunk/src/target/OM-2007/libraries/mokoui/mokoui.pro
trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro
Log:
mokoui: good bye moko-toolbar, hello moko-toolbox
Modified: trunk/src/target/OM-2007/artwork/themes/openmoko-standard/gtk-2.0/gtkrc
===================================================================
--- trunk/src/target/OM-2007/artwork/themes/openmoko-standard/gtk-2.0/gtkrc 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/artwork/themes/openmoko-standard/gtk-2.0/gtkrc 2006-10-23 15:11:34 UTC (rev 113)
@@ -1,4 +1,4 @@
-gtk-font-name = "Vera Sans 16"
+# gtk-font-name = "Vera Sans 16"
# pixmap_path "/local/pkg/openmoko/OM-2007/artwork/themes/openmoko-standard/gtk-2.0"
Added: trunk/src/target/OM-2007/examples/examples.pro
===================================================================
--- trunk/src/target/OM-2007/examples/examples.pro 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/examples/examples.pro 2006-10-23 15:11:34 UTC (rev 113)
@@ -0,0 +1,3 @@
+TEMPLATE = subdirs
+SUBDIRS = openmoko-paned-demo openmoko-finger-demo
+
Modified: trunk/src/target/OM-2007/examples/openmoko-paned-demo/demo-main.c
===================================================================
--- trunk/src/target/OM-2007/examples/openmoko-paned-demo/demo-main.c 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/examples/openmoko-paned-demo/demo-main.c 2006-10-23 15:11:34 UTC (rev 113)
@@ -19,7 +19,7 @@
#include <mokoui/moko-application.h>
#include <mokoui/moko-paned-window.h>
-#include <mokoui/moko-toolbar.h>
+#include <mokoui/moko-toolbox.h>
#include <gtk/gtkactiongroup.h>
#include <gtk/gtkbutton.h>
@@ -73,10 +73,12 @@
moko_paned_window_set_upper_pane( window, GTK_WIDGET(navigationlist) );
/* tool bar */
- MokoToolBar* toolbar = MOKO_TOOLBAR(moko_toolbar_new());
+ MokoToolBox* toolbox = MOKO_TOOL_BOX(moko_tool_box_new());
+ GtkToolbar* toolbar = moko_tool_box_get_tool_bar(toolbox);
GtkToolButton* tool_search = GTK_TOOL_BUTTON(gtk_tool_button_new( NULL, "search" ));
+ //moko_tool_box_show_search_button( toolbox, TRUE )
gtk_toolbar_insert( GTK_TOOLBAR(toolbar), tool_search, 0 );
- moko_paned_window_add_toolbar( window, GTK_TOOLBAR(toolbar) );
+ moko_paned_window_add_toolbox( window, toolbox );
GtkToolButton* tool_action1 = GTK_TOOL_BUTTON(gtk_tool_button_new( NULL, "action1" ));
gtk_toolbar_insert( GTK_TOOLBAR(toolbar), tool_action1, 1 );
Modified: trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.c
===================================================================
--- trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.c 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.c 2006-10-23 15:11:34 UTC (rev 113)
@@ -18,8 +18,9 @@
*/
#include "moko-paned-window.h"
#include "moko-menubox.h"
-#include "moko-toolbar.h"
+#include "moko-toolbox.h"
+#include <gtk/gtktoolbar.h>
#include <gtk/gtkvbox.h>
#include <gtk/gtkvpaned.h>
@@ -31,7 +32,7 @@
GtkVBox* upper;
GtkVBox* lower;
MokoMenuBox* menubox;
- MokoToolBox* toolbar;
+ MokoToolBox* toolbox;
} MokoPanedWindowPriv;
@@ -97,7 +98,7 @@
priv->lower = gtk_vbox_new( FALSE, 0 );
gtk_paned_add2( GTK_PANED(priv->outerframe), GTK_WIDGET(priv->lower) );
priv->menubox = NULL;
- priv->toolbar = NULL;
+ priv->toolbox = NULL;
}
GtkWidget* moko_paned_window_new() /* Construction */
@@ -153,12 +154,12 @@
gtk_box_pack_start( GTK_BOX(priv->lower), child, TRUE, TRUE, 0 );
}
-void moko_paned_window_add_toolbar(MokoPanedWindow* self, GtkToolbar* toolbar)
+void moko_paned_window_add_toolbox(MokoPanedWindow* self, MokoToolBox* toolbox)
{
- g_debug( "moko_paned_window_add_toolbar" );
+ g_debug( "moko_paned_window_add_toolbox" );
MokoPanedWindowPriv* priv = MOKO_PANED_WINDOW_GET_PRIVATE(self);
- gtk_box_pack_end( GTK_BOX(priv->upper), toolbar, FALSE, FALSE, 0 );
- gtk_box_reorder_child( GTK_BOX(priv->upper), toolbar, 1 );
+ gtk_box_pack_end( GTK_BOX(priv->upper), toolbox, FALSE, FALSE, 0 );
+ gtk_box_reorder_child( GTK_BOX(priv->upper), toolbox, 1 );
}
GtkMenuBar* moko_paned_window_get_menubox(MokoPanedWindow* self)
Modified: trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.h
===================================================================
--- trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.h 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/libraries/mokoui/moko-paned-window.h 2006-10-23 15:11:34 UTC (rev 113)
@@ -23,8 +23,8 @@
#include <glib-object.h>
#include <gtk/gtkmenu.h>
#include <gtk/gtkmenubar.h>
-#include <gtk/gtktoolbar.h>
#include "moko-window.h"
+#include "moko-toolbox.h"
G_BEGIN_DECLS
@@ -63,7 +63,7 @@
void moko_paned_window_set_upper_pane(MokoPanedWindow* self, GtkWidget* child);
void moko_paned_window_set_lower_pane(MokoPanedWindow* self, GtkWidget* child);
-void moko_paned_window_add_toolbar(MokoPanedWindow* self, GtkToolbar* toolbar);
+void moko_paned_window_add_toolbox(MokoPanedWindow* self, MokoToolBox* toolbox);
G_END_DECLS
Deleted: trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.c
===================================================================
--- trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.c 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.c 2006-10-23 15:11:34 UTC (rev 113)
@@ -1,85 +0,0 @@
-/*
- * libmokoui -- OpenMoko Application Framework UI Library
- *
- * Authored By Michael 'Mickey' Lauer <mlauer at vanille-media.de>
- *
- * Copyright (C) 2006 First International Computer Inc.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Lesser Public License as published by
- * the Free Software Foundation; version 2.1 of the license.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser Public License for more details.
- *
- * Current Version: $Rev$ ($Date$) [$Author$]
- */
-#include "moko-toolbar.h"
-
-/* add your signals here */
-enum {
- MOKO_TOOL_BOX_SIGNAL,
- LAST_SIGNAL
-};
-
-static void moko_tool_box_class_init (MokoToolBoxClass *klass);
-static void moko_tool_box_init (MokoToolBox *f);
-
-static guint moko_tool_box_signals[LAST_SIGNAL] = { 0 };
-
-GType moko_tool_box_get_type (void) /* Typechecking */
-{
- static GType self_type = 0;
-
- if (!self_type)
- {
- static const GTypeInfo f_info =
- {
- sizeof (MokoToolBoxClass),
- NULL, /* base_init */
- NULL, /* base_finalize */
- (GClassInitFunc) moko_tool_box_class_init,
- NULL, /* class_finalize */
- NULL, /* class_data */
- sizeof (MokoToolBox),
- 0,
- (GInstanceInitFunc) moko_tool_box_init,
- };
-
- /* add the type of your parent class here */
- self_type = g_type_register_static(GTK_TYPE_TOOLBAR, "MokoToolBox", &f_info, 0);
- }
-
- return self_type;
-}
-
-static void moko_tool_box_class_init (MokoToolBoxClass *klass) /* Class Initialization */
-{
- moko_tool_box_signals[MOKO_TOOL_BOX_SIGNAL] = g_signal_new ("moko_tool_box",
- G_TYPE_FROM_CLASS (klass),
- G_SIGNAL_RUN_FIRST | G_SIGNAL_ACTION,
- G_STRUCT_OFFSET (MokoToolBoxClass, moko_tool_box),
- NULL,
- NULL,
- g_cclosure_marshal_VOID__VOID,
- G_TYPE_NONE, 0);
-}
-
-static void moko_tool_box_init (MokoToolBox *f) /* Instance Construction */
-{
- /* populate your widget here */
-}
-
-GtkWidget* moko_tool_box_new() /* Construction */
-{
- return GTK_WIDGET(g_object_new(moko_tool_box_get_type(), NULL));
-}
-
-void moko_tool_box_clear(MokoToolBox *f) /* Destruction */
-{
- /* destruct your widgets here */
-}
-
-/* add new methods here */
Deleted: trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.h
===================================================================
--- trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.h 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.h 2006-10-23 15:11:34 UTC (rev 113)
@@ -1,58 +0,0 @@
-/*
- * libmokoui -- OpenMoko Application Framework UI Library
- *
- * Authored By Michael 'Mickey' Lauer <mlauer at vanille-media.de>
- *
- * Copyright (C) 2006 First International Computer Inc.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Lesser Public License as published by
- * the Free Software Foundation; version 2.1 of the license.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser Public License for more details.
- *
- * Current Version: $Rev$ ($Date$) [$Author$]
- */
-#ifndef _MOKO_TOOL_BOX_H_
-#define _MOKO_TOOL_BOX_H_
-
-#include <glib.h>
-#include <glib-object.h>
-#include <gtk/gtktoolbar.h>
-
-G_BEGIN_DECLS
-
-#define MOKO_TYPE_TOOLBAR (moko_tool_box_get_type())
-#define MOKO_TOOL_BOX(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MOKO_TYPE_TOOLBAR, MokoToolBox))
-#define MOKO_TOOL_BOX_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MOKO_TYPE_TOOLBAR, MokoToolBoxClass))
-#define IS_MOKO_TOOL_BOX(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MOKO_TYPE_TOOLBAR))
-#define IS_MOKO_TOOL_BOX_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MOKO_TYPE_TOOLBAR))
-
-typedef struct _MokoToolBox MokoToolBox;
-typedef struct _MokoToolBoxClass MokoToolBoxClass;
-
-struct _MokoToolBox
-{
- GtkToolbar parent;
- /* add pointers to new members here */
-};
-
-struct _MokoToolBoxClass
-{
- /* add your parent class here */
- GtkToolbarClass parent_class;
- void (*moko_tool_box) (MokoToolBox *self);
-};
-
-GType moko_tool_box_get_type (void);
-GtkWidget* moko_tool_box_new (void);
-void moko_tool_box_clear (MokoToolBox *self);
-
-/* add additional methods here */
-
-G_END_DECLS
-
-#endif /* _MOKO_TOOL_BOX_H_ */
Copied: trunk/src/target/OM-2007/libraries/mokoui/moko-toolbox.c (from rev 112, trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.c)
===================================================================
--- trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.c 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/libraries/mokoui/moko-toolbox.c 2006-10-23 15:11:34 UTC (rev 113)
@@ -0,0 +1,105 @@
+/*
+ * libmokoui -- OpenMoko Application Framework UI Library
+ *
+ * Authored By Michael 'Mickey' Lauer <mlauer at vanille-media.de>
+ *
+ * Copyright (C) 2006 First International Computer Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser Public License as published by
+ * the Free Software Foundation; version 2.1 of the license.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser Public License for more details.
+ *
+ * Current Version: $Rev$ ($Date$) [$Author$]
+ */
+#include "moko-toolbox.h"
+
+#define MOKO_TOOL_BOX_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), MOKO_TYPE_TOOL_BOX, MokoToolBoxPriv));
+
+typedef struct _MokoToolBoxPriv
+{
+ GtkToolbar* toolbar;
+ GtkVBox* searchbar;
+} MokoToolBoxPriv;
+
+/* add your signals here */
+enum {
+ MOKO_TOOL_BOX_SIGNAL,
+ LAST_SIGNAL
+};
+
+static void moko_tool_box_class_init (MokoToolBoxClass *klass);
+static void moko_tool_box_init (MokoToolBox *self);
+
+static guint moko_tool_box_signals[LAST_SIGNAL] = { 0 };
+
+GType moko_tool_box_get_type (void) /* Typechecking */
+{
+ static GType self_type = 0;
+
+ if (!self_type)
+ {
+ static const GTypeInfo self_info =
+ {
+ sizeof (MokoToolBoxClass),
+ NULL, /* base_init */
+ NULL, /* base_finalize */
+ (GClassInitFunc) moko_tool_box_class_init,
+ NULL, /* class_finalize */
+ NULL, /* class_data */
+ sizeof (MokoToolBox),
+ 0,
+ (GInstanceInitFunc) moko_tool_box_init,
+ };
+
+ /* add the type of your parent class here */
+ self_type = g_type_register_static(GTK_TYPE_VBOX, "MokoToolBox", &self_info, 0);
+ }
+
+ return self_type;
+}
+
+static void moko_tool_box_class_init (MokoToolBoxClass *klass) /* Class Initialization */
+{
+ g_type_class_add_private(klass, sizeof(MokoToolBoxPriv));
+
+ moko_tool_box_signals[MOKO_TOOL_BOX_SIGNAL] = g_signal_new ("moko_tool_box",
+ G_TYPE_FROM_CLASS (klass),
+ G_SIGNAL_RUN_FIRST | G_SIGNAL_ACTION,
+ G_STRUCT_OFFSET (MokoToolBoxClass, moko_tool_box),
+ NULL,
+ NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
+}
+
+static void moko_tool_box_init(MokoToolBox* self) /* Instance Construction */
+{
+ MokoToolBoxPriv* priv = MOKO_TOOL_BOX_GET_PRIVATE(self);
+ priv->toolbar = gtk_toolbar_new();
+ gtk_box_pack_start( GTK_BOX(self), priv->toolbar, TRUE, TRUE, 0 );
+
+ /* populate your widget here */
+}
+
+GtkWidget* moko_tool_box_new() /* Construction */
+{
+ return GTK_WIDGET(g_object_new(moko_tool_box_get_type(), NULL));
+}
+
+void moko_tool_box_clear(MokoToolBox* self) /* Destruction */
+{
+ /* destruct your widgets here */
+}
+
+/* add new methods here */
+
+GtkToolbar* moko_tool_box_get_tool_bar(MokoToolBox* self)
+{
+ MokoToolBoxPriv* priv = MOKO_TOOL_BOX_GET_PRIVATE(self);
+ return priv->toolbar;
+}
Copied: trunk/src/target/OM-2007/libraries/mokoui/moko-toolbox.h (from rev 112, trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.h)
===================================================================
--- trunk/src/target/OM-2007/libraries/mokoui/moko-toolbar.h 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/libraries/mokoui/moko-toolbox.h 2006-10-23 15:11:34 UTC (rev 113)
@@ -0,0 +1,60 @@
+/*
+ * libmokoui -- OpenMoko Application Framework UI Library
+ *
+ * Authored By Michael 'Mickey' Lauer <mlauer at vanille-media.de>
+ *
+ * Copyright (C) 2006 First International Computer Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser Public License as published by
+ * the Free Software Foundation; version 2.1 of the license.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser Public License for more details.
+ *
+ * Current Version: $Rev$ ($Date$) [$Author$]
+ */
+#ifndef _MOKO_TOOL_BOX_H_
+#define _MOKO_TOOL_BOX_H_
+
+#include <glib.h>
+#include <glib-object.h>
+#include <gtk/gtkvbox.h>
+#include <gtk/gtktoolbar.h>
+
+G_BEGIN_DECLS
+
+#define MOKO_TYPE_TOOL_BOX (moko_tool_box_get_type())
+#define MOKO_TOOL_BOX(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MOKO_TYPE_TOOL_BOX, MokoToolBox))
+#define MOKO_TOOL_BOX_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MOKO_TYPE_TOOL_BOX, MokoToolBoxClass))
+#define IS_MOKO_TOOL_BOX(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MOKO_TYPE_TOOL_BOX))
+#define IS_MOKO_TOOL_BOX_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MOKO_TYPE_TOOL_BOX))
+
+typedef struct _MokoToolBox MokoToolBox;
+typedef struct _MokoToolBoxClass MokoToolBoxClass;
+
+struct _MokoToolBox
+{
+ GtkVBox parent;
+ /* add pointers to new members here */
+};
+
+struct _MokoToolBoxClass
+{
+ /* add your parent class here */
+ GtkVBoxClass parent_class;
+ void (*moko_tool_box) (MokoToolBox *self);
+};
+
+GType moko_tool_box_get_type (void);
+GtkWidget* moko_tool_box_new (void);
+void moko_tool_box_clear (MokoToolBox* self);
+
+/* add additional methods here */
+GtkToolbar* moko_tool_box_get_tool_bar(MokoToolBox* self);
+
+G_END_DECLS
+
+#endif /* _MOKO_TOOL_BOX_H_ */
Modified: trunk/src/target/OM-2007/libraries/mokoui/mokoui.pro
===================================================================
--- trunk/src/target/OM-2007/libraries/mokoui/mokoui.pro 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/libraries/mokoui/mokoui.pro 2006-10-23 15:11:34 UTC (rev 113)
@@ -1,8 +1,8 @@
TEMPLATE = lib
VERSION = 0.0.1
-HEADERS = moko-application.h moko-window.h moko-finger-window.h moko-paned-window.h moko-menubox.h moko-toolbar.h
-SOURCES = moko-application.c moko-window.c moko-finger-window.c moko-paned-window.c moko-menubox.c moko-toolbar.c
+HEADERS = moko-application.h moko-window.h moko-finger-window.h moko-paned-window.h moko-menubox.h moko-toolbox.h
+SOURCES = moko-application.c moko-window.c moko-finger-window.c moko-paned-window.c moko-menubox.c moko-toolbox.c
PKGCONFIG += gtk+-2.0
Modified: trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro
===================================================================
--- trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro 2006-10-23 14:40:29 UTC (rev 112)
+++ trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro 2006-10-23 15:11:34 UTC (rev 113)
@@ -1,4 +1,5 @@
TEMPLATE = subdirs
-SUBDIRS = openmoko-panel-search
+SUBDIRS =
+# SUBDIRS = openmoko-panel-search
More information about the commitlog
mailing list