]> git.tdb.fi Git - r2c2.git/blob - source/designer/layoutbar.cpp
Split the single large toolbar into a few smaller collapsible ones
[r2c2.git] / source / designer / layoutbar.cpp
1 /* $Id$
2
3 This file is part of R²C²
4 Copyright © 2010 Mikkosoft Productions, Mikko Rasa
5 Distributed under the GPL
6 */
7
8 #include "designer.h"
9 #include "layoutbar.h"
10
11 using namespace Msp;
12
13 Layoutbar::Layoutbar(Designer &designer):
14         Toolbar("Layout", 120)
15 {
16         GLtk::Button *btn;
17
18         pnl_content->add(*(btn = new GLtk::Button("Load")));
19         btn->set_geometry(GLtk::Geometry(0, 10, 40, 24));
20         btn->set_tooltip("Load layout (not implemented)");
21
22         pnl_content->add(*(btn = new GLtk::Button("Save")));
23         btn->set_geometry(GLtk::Geometry(40, 10, 40, 24));
24         btn->set_tooltip("Save current layout");
25         btn->signal_clicked.connect(sigc::mem_fun(&designer, &Designer::save));
26
27         pnl_content->add(*(btn = new GLtk::Button("Quit")));
28         btn->set_geometry(GLtk::Geometry(80, 10, 40, 24));
29         btn->set_style("red");
30         btn->set_tooltip("Exit Designer");
31         btn->signal_clicked.connect(sigc::mem_fun(&designer, &Designer::quit));
32 }