1 // Copyright (C) 2010, 2012, 2014 Ben Asselstine 2 // 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. 7 // 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. 12 // 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 16 // 02110-1301, USA. 17 18 #pragma once 19 #ifndef ITEM_REPORT_DIALOG_H 20 #define ITEM_REPORT_DIALOG_H 21 22 #include <gtkmm.h> 23 24 #include "itemmap.h" 25 #include "player.h" 26 #include "lw-dialog.h" 27 28 class Stack; 29 class MapBackpack; 30 // dialog for showing where the items are 31 class ItemReportDialog: public LwDialog 32 { 33 public: 34 ItemReportDialog(Gtk::Window &parent, std::list<Stack*> item_laden_stacks, std::list<MapBackpack*> bags); ~ItemReportDialog()35 ~ItemReportDialog() {delete itemmap;}; 36 hide()37 void hide() {dialog->hide();}; 38 void run(); 39 40 private: 41 std::list<Stack*> stacks; 42 std::list<MapBackpack*> bags; 43 ItemMap* itemmap; 44 45 Gtk::Image *map_image; 46 47 void on_map_changed(Cairo::RefPtr<Cairo::Surface> map); 48 void fill_in_item_info(); 49 Gtk::Label *label; 50 51 }; 52 53 #endif 54