Skip to content

Commit

Permalink
made compatible with gtk3.10
Browse files Browse the repository at this point in the history
  • Loading branch information
mbfoss committed Feb 19, 2017
1 parent 7ef8970 commit 162b908
Show file tree
Hide file tree
Showing 5 changed files with 246 additions and 209 deletions.
17 changes: 14 additions & 3 deletions src/MainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -137,9 +137,20 @@ void MainWindow::run(Glib::RefPtr<Gtk::Application> app)
{
Glib::RefPtr<Gtk::Builder> builder = Gtk::Builder::create();

builder->add_from_resource("/nethogs_gui/window.glade");
builder->add_from_resource("/nethogs_gui/headerbar.ui");

try{
builder->add_from_resource("/nethogs_gui/window.glade");
}
catch(Gtk::BuilderError const& e){
std::cout << e.what() << std::endl;
return;
}
try{
builder->add_from_resource("/nethogs_gui/headerbar.ui");
}
catch(Gtk::BuilderError const& e){
std::cout << e.what() << std::endl;
return;
}

//get widgets
m_window = loadWiget<Gtk::ApplicationWindow>(builder, "main_window");
Expand Down
Loading

0 comments on commit 162b908

Please sign in to comment.