mirror of https://github.com/KLayout/klayout.git
WIP: 'open window' menu item
This commit is contained in:
parent
64406522fe
commit
05c16c9024
|
|
@ -43,6 +43,18 @@ module D25
|
|||
|
||||
mw.menu.insert_item("tools_menu.#{cat}.end", "edit_script", @edit_action)
|
||||
|
||||
@open_action = RBA::Action::new
|
||||
@open_action.title = "Open Window"
|
||||
@open_action.on_triggered do
|
||||
if ! RBA::LayoutView::current
|
||||
RBA::MessageBox::critical("Error", "No layout loaded for running 2.5d view on", RBA::MessageBox::Ok)
|
||||
else
|
||||
RBA::LayoutView::current.open_d25_view
|
||||
end
|
||||
end
|
||||
|
||||
mw.menu.insert_item("tools_menu.#{cat}.end", "open_window", @open_action)
|
||||
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
|||
|
|
@ -52,10 +52,9 @@ public:
|
|||
return 0;
|
||||
}
|
||||
|
||||
virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const
|
||||
virtual void get_menu_entries (std::vector<lay::MenuEntry> & /*menu_entries*/) const
|
||||
{
|
||||
lay::PluginDeclaration::get_menu_entries (menu_entries);
|
||||
menu_entries.push_back (lay::menu_item ("lay::d25_view", "d25_view:edit", "tools_menu.post_verification_group", tl::to_string (QObject::tr ("2.5d View - experimental"))));
|
||||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
virtual bool configure (const std::string & /*name*/, const std::string & /*value*/)
|
||||
|
|
|
|||
|
|
@ -170,7 +170,7 @@ D25View::finish ()
|
|||
{
|
||||
mp_ui->d25_view->finish ();
|
||||
|
||||
// @@@ install
|
||||
// @@@ install layer properties widget
|
||||
|
||||
mp_ui->d25_view->reset ();
|
||||
mp_ui->d25_view->set_cam_azimuth (0.0);
|
||||
|
|
|
|||
Loading…
Reference in New Issue