1 // Copyright (C) 2007, 2008, 2009 Ben Asselstine
3 // This program is free software; you can redistribute it and/or modify
4 // it under the terms of the GNU General Public License as published by
5 // the Free Software Foundation; either version 3 of the License, or
6 // (at your option) any later version.
8 // This program is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 // GNU Library General Public License for more details.
13 // You should have received a copy of the GNU General Public License
14 // along with this program; if not, write to the Free Software
15 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
18 #ifndef QUEST_REPORT_DIALOG_H
19 #define QUEST_REPORT_DIALOG_H
23 #include <sigc++/trackable.h>
31 #include "decorated.h"
33 // dialog for depicting a quest
34 class QuestReportDialog: public Decorated
37 QuestReportDialog(std::vector<Quest *>quests, Hero *preferred_hero);
40 void set_parent_window(Gtk::Window &parent);
50 Gtk::Image *map_image;
52 Gtk::Label *hero_label;
54 std::vector<Quest*> quests;
57 void on_map_changed(Glib::RefPtr<Gdk::Pixmap> map);
58 Gtk::TreeView *heroes_treeview;
60 class HeroesColumns: public Gtk::TreeModelColumnRecord {
63 { add(hero_name); add(quest);}
65 Gtk::TreeModelColumn<Glib::ustring> hero_name;
66 Gtk::TreeModelColumn<Quest*> quest;
68 const HeroesColumns heroes_columns;
69 Glib::RefPtr<Gtk::ListStore> heroes_list;
71 void fill_quest_info(Quest *q);
73 void add_questing_hero(Quest *quest, Hero *h);
75 void on_hero_changed();