Exemple #1
0
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;
}
Exemple #2
0
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;
}
Exemple #3
0
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();
}
Exemple #4
0
void App::multimeter_it() {
    buildmultimeter();
    multitransient_ = new TransientWindow(multimeter_);
    multitransient_->map();
}
Exemple #5
0
void App::meter_it() {
    buildmeter();
    transient_ = new TransientWindow(meter_);
    transient_->map();
}