]> git.tdb.fi Git - r2c2.git/blobdiff - source/designer/layoutbar.cpp
Split the single large toolbar into a few smaller collapsible ones
[r2c2.git] / source / designer / layoutbar.cpp
diff --git a/source/designer/layoutbar.cpp b/source/designer/layoutbar.cpp
new file mode 100644 (file)
index 0000000..d47485f
--- /dev/null
@@ -0,0 +1,32 @@
+/* $Id$
+
+This file is part of R²C²
+Copyright © 2010 Mikkosoft Productions, Mikko Rasa
+Distributed under the GPL
+*/
+
+#include "designer.h"
+#include "layoutbar.h"
+
+using namespace Msp;
+
+Layoutbar::Layoutbar(Designer &designer):
+       Toolbar("Layout", 120)
+{
+       GLtk::Button *btn;
+
+       pnl_content->add(*(btn = new GLtk::Button("Load")));
+       btn->set_geometry(GLtk::Geometry(0, 10, 40, 24));
+       btn->set_tooltip("Load layout (not implemented)");
+
+       pnl_content->add(*(btn = new GLtk::Button("Save")));
+       btn->set_geometry(GLtk::Geometry(40, 10, 40, 24));
+       btn->set_tooltip("Save current layout");
+       btn->signal_clicked.connect(sigc::mem_fun(&designer, &Designer::save));
+
+       pnl_content->add(*(btn = new GLtk::Button("Quit")));
+       btn->set_geometry(GLtk::Geometry(80, 10, 40, 24));
+       btn->set_style("red");
+       btn->set_tooltip("Exit Designer");
+       btn->signal_clicked.connect(sigc::mem_fun(&designer, &Designer::quit));
+}