void Editor::RemoveDialog (Glyph* g) { for (ListUpdater(EditorImpl) i(*_impl); i.more(); i.next()) { TransientWindow* t = i.cur(); if (t->glyph() == g) { t->unmap(); i.remove_cur(); delete t; break; } } }
boolean Dialog::post_for_aligned(Window* w, float x_align, float y_align) { TransientWindow* t = new TransientWindow(this); t->style(new Style(style())); t->transient_for(w); t->wm_delete(new DialogHandler(this)); t->place(w->left() + 0.5 * w->width(), w->bottom() + 0.5 * w->height()); t->align(x_align, y_align); t->map(); boolean b = run(); t->unmap(); t->display()->sync(); delete t; return b; }
boolean Dialog::post_at_aligned( Coord x, Coord y, float x_align, float y_align ) { TransientWindow* t = new TransientWindow(this); t->style(new Style(style())); t->wm_delete(new DialogHandler(this)); t->place(x, y); t->align(x_align, y_align); t->map(); boolean b = run(); t->unmap(); t->display()->sync(); delete t; return b; }
void Editor::InsertDialog (Glyph* g) { ManagedWindow* w = GetWindow(); if (w != nil) w->deiconify(); TransientWindow* dialog = nil; for (ListItr(EditorImpl) i(*_impl); i.more(); i.next()) { TransientWindow* t = i.cur(); if (t->glyph() == g) { dialog = t; break; } } if (dialog == nil) { dialog = new TransientWindow(g); _impl->prepend(dialog); } dialog->transient_for(w); dialog->place( w->left() + w->width() * 0.5, w->bottom() + w->height() * 0.5 ); dialog->align(0.5, 0.5); dialog->map(); }
void App::cancel_multimeter() { multitransient_->unmap(); multitransient_->display()->sync(); delete multitransient_; }
void App::cancel_meter() { transient_->unmap(); transient_->display()->sync(); delete transient_; }
void App::multimeter_it() { buildmultimeter(); multitransient_ = new TransientWindow(multimeter_); multitransient_->map(); }
void App::meter_it() { buildmeter(); transient_ = new TransientWindow(meter_); transient_->map(); }