~ubuntu-branches/ubuntu/raring/lordsawar/raring

« back to all changes in this revision

Viewing changes to src/editor/select-army-dialog.h

  • Committer: Bazaar Package Importer
  • Author(s): Barry deFreese, Barry deFreese, Gonéri Le Bouder
  • Date: 2008-06-17 11:15:26 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20080617111526-yjyvu9df50zmpdo0
Tags: 0.0.9-1
[ Barry deFreese ]
* New upstream release.
  + Fixes gcc-4.3 builds so drop ftbfs_gcc-4.3_fix.diff.
  + Add new build-dependency for libgnet-dev.
* Add simple man page for new lordsawar-tile-editor.
* Add desktop file for lordsawar-tile-editor.
* Remove French translation on install.

[ Gonéri Le Bouder ]
* bump Debian Policy to 3.8.0. No change needed.
* fix wording in the 0.0.8-3 entry of the Debian changelog

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
//  Copyright (C) 2007, Ole Laursen
 
2
//  Copyright (C) 2007, 2008 Ben Asselstine
 
3
//
1
4
//  This program is free software; you can redistribute it and/or modify
2
5
//  it under the terms of the GNU General Public License as published by
3
6
//  the Free Software Foundation; either version 2 of the License, or
10
13
//
11
14
//  You should have received a copy of the GNU General Public License
12
15
//  along with this program; if not, write to the Free Software
13
 
//  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
16
//  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 
 
17
//  02110-1301, USA.
14
18
 
15
19
#ifndef SELECT_ARMY_DIALOG_H
16
20
#define SELECT_ARMY_DIALOG_H
23
27
#include <gtkmm/table.h>
24
28
#include <gtkmm/togglebutton.h>
25
29
#include <gtkmm/button.h>
26
 
#include <gtkmm/comboboxtext.h>
27
30
#include <SDL/SDL_types.h>
28
31
 
29
32
#include "../gui/army-info-tip.h"
32
35
class City;
33
36
class Player;
34
37
 
35
 
// dialog for buying a production slot for a city
 
38
//! Scenario editor.  Select an Army prototype.
36
39
class SelectArmyDialog: public sigc::trackable
37
40
{
38
41
 public:
39
 
    SelectArmyDialog(Player *p);
 
42
    SelectArmyDialog(Player *p, bool defends_ruins = false,
 
43
                     bool rewardable = false);
40
44
 
41
45
    void set_parent_window(Gtk::Window &parent);
42
46
 
47
51
 private:
48
52
    std::auto_ptr<Gtk::Dialog> dialog;
49
53
    std::auto_ptr<ArmyInfoTip> army_info_tip;
50
 
    Gtk::ComboBoxText *armyset_combobox;
51
54
    Gtk::Label *army_info_label1;
52
55
    Gtk::Label *army_info_label2;
53
56
    Gtk::Table *toggles_table;
56
59
 
57
60
    const Army *selected_army;
58
61
    Player *player;
 
62
    bool d_defends_ruins;
 
63
    bool d_awardable;
59
64
 
60
65
    std::vector<Gtk::ToggleButton *> army_toggles;
61
66
    bool ignore_toggles;
63
68
 
64
69
    void on_army_toggled(Gtk::ToggleButton *toggle);
65
70
    bool on_army_button_event(GdkEventButton *e, Gtk::ToggleButton *toggle);
66
 
    void on_armyset_changed();
67
71
    
68
72
    void fill_in_army_toggles();
69
73
    void fill_in_army_info();