I create one new project using vc++ express, it's OK.
Confused by the IDE, i diff the two project files(vcporj). it maybe because
the part of VC++ property sheet......

gtkmm provides two MSVC 2005 files named:
gtkmm-vc80-2_4.vsprops
gtkmm-vc80-d-2_4.vsprops

Maybe because i add these two property files twice.....



2010/3/20 Zhu Bicen <[email protected]>

> Below code can be compiled and launched successfully, but after exit it(by
> hitting the close button ) it crash.
> VC++ 2005 express give me following info:
>
> "Windows has triggered a breakpoint in LogLeader.exe.
> This may be due to a corruption of the heap, and indicates a bug in
> LogLeader.exe or any of the DLLs it has loaded.
> The output window may have more diagnostic information"
>
> How to fix this? Any comments or advice is appreciated!
> Thanks!
>
>
> class LogListView : public Gtk::ScrolledWindow
> {
> public:
>     LogListView();
>     virtual ~LogListView(){}
> private:
>     Gtk::TreeView m_TreeView;
>     Glib::RefPtr<Gtk::ListStore> m_refListStore;
>     struct ModelColumns : public Gtk::TreeModel::ColumnRecord
>     {
>         Gtk::TreeModelColumn<Glib::ustring> group;
>         Gtk::TreeModelColumn<Glib::ustring> code;
>         Gtk::TreeModelColumn<Glib::ustring> timeStamp;
>
>         ModelColumns() { add(group); add(code); add(timeStamp); }
>     };
>     ModelColumns m_columns;
> };
> LogListView::LogListView()
> {
>     //create module
>     m_refListStore= Gtk::ListStore::create(m_columns);
>     //create treeView
>     m_TreeView.set_model(m_refListStore);
>     m_TreeView.set_rules_hint();
>     m_TreeView.append_column("Group", m_columns.group );
>     m_TreeView.append_column("Code", m_columns.code);
>     m_TreeView.append_column("TimeStamp", m_columns.timeStamp);
>     add( m_TreeView );
>     show_all();
> }
> class MainWindow : public Gtk::Window
> {
> public:
>     MainWindow()
>     {
>         set_title("LoggerLeader");
>         add( logListView_ );
>         set_default_size(600, 500);
>         show_all();
>     }
>     void on_button_quit()
>     {
>         hide();
>     }
>
>     ~MainWindow(){}
> private:
>
>     LogListView logListView_;
> };
> int main(int argc, char *argv[])
> {
>     Gtk::Main kit(argc, argv);
>     MainWindow window;
>     Gtk::Main::run(window);
>     return 0;
> }
>
> --
> Best Regards
> Bicen Zhu
>



-- 
Best Regards
Bicen Zhu
_______________________________________________
gtkmm-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/gtkmm-list

Reply via email to