mirror of https://github.com/GNOME/gimp.git
app/display/gimpdisplayshell.c app/gui/about-dialog.c
2002-10-25 Michael Natterer <mitch@gimp.org> * app/display/gimpdisplayshell.c * app/gui/about-dialog.c * app/gui/convert-dialog.c * app/gui/dialogs-commands.c * app/gui/file-commands.c * app/gui/palette-import-dialog.c * app/tools/gimptexttool.c * app/widgets/gimpdialogfactory.c * app/widgets/gimpdocumentview.c * app/widgets/gimpwidgets-utils.c * libgimpwidgets/gimpfileselection.c * plug-ins/FractalExplorer/Dialogs.c * plug-ins/FractalExplorer/FractalExplorer.c * plug-ins/common/AlienMap.c * plug-ins/common/AlienMap2.c * plug-ins/common/spheredesigner.c * plug-ins/flame/flame.c * plug-ins/gfig/gfig.c * plug-ins/gimpressionist/general.c * plug-ins/gimpressionist/gimpressionist.c: replaced all sorts of gtk_widget_show()/gdk_window_rise() combinations by gtk_window_present().
This commit is contained in:
parent
1b91957176
commit
b5d27fc4ac
25
ChangeLog
25
ChangeLog
|
@ -1,3 +1,28 @@
|
|||
2002-10-25 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/display/gimpdisplayshell.c
|
||||
* app/gui/about-dialog.c
|
||||
* app/gui/convert-dialog.c
|
||||
* app/gui/dialogs-commands.c
|
||||
* app/gui/file-commands.c
|
||||
* app/gui/palette-import-dialog.c
|
||||
* app/tools/gimptexttool.c
|
||||
* app/widgets/gimpdialogfactory.c
|
||||
* app/widgets/gimpdocumentview.c
|
||||
* app/widgets/gimpwidgets-utils.c
|
||||
* libgimpwidgets/gimpfileselection.c
|
||||
* plug-ins/FractalExplorer/Dialogs.c
|
||||
* plug-ins/FractalExplorer/FractalExplorer.c
|
||||
* plug-ins/common/AlienMap.c
|
||||
* plug-ins/common/AlienMap2.c
|
||||
* plug-ins/common/spheredesigner.c
|
||||
* plug-ins/flame/flame.c
|
||||
* plug-ins/gfig/gfig.c
|
||||
* plug-ins/gimpressionist/general.c
|
||||
* plug-ins/gimpressionist/gimpressionist.c: replaced all sorts of
|
||||
gtk_widget_show()/gdk_window_rise() combinations by
|
||||
gtk_window_present().
|
||||
|
||||
2002-10-25 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/gui/Makefile.am
|
||||
|
|
|
@ -392,11 +392,7 @@ dialogs_show_toolbox (void)
|
|||
{
|
||||
if (GTK_WIDGET_TOPLEVEL (list->data))
|
||||
{
|
||||
if (GTK_WIDGET_VISIBLE (list->data))
|
||||
gtk_widget_show (GTK_WIDGET (list->data));
|
||||
else
|
||||
gdk_window_raise (GTK_WIDGET (list->data)->window);
|
||||
|
||||
gtk_window_present (GTK_WINDOW (list->data));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -217,7 +217,7 @@ file_revert_cmd_callback (GtkWidget *widget,
|
|||
}
|
||||
else if (query_box)
|
||||
{
|
||||
gdk_window_raise (query_box->window);
|
||||
gtk_window_present (GTK_WINDOW (query_box->window));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -255,8 +255,6 @@ about_dialog_create (void)
|
|||
|
||||
if (! GTK_WIDGET_VISIBLE (about_dialog))
|
||||
{
|
||||
gtk_widget_show (about_dialog);
|
||||
|
||||
do_animation = TRUE;
|
||||
do_scrolling = FALSE;
|
||||
scroll_state = 0;
|
||||
|
@ -291,10 +289,8 @@ about_dialog_create (void)
|
|||
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gdk_window_raise (about_dialog->window);
|
||||
}
|
||||
|
||||
gtk_window_present (GTK_WINDOW (about_dialog));
|
||||
|
||||
return about_dialog;
|
||||
}
|
||||
|
|
|
@ -541,6 +541,6 @@ indexed_custom_palette_button_callback (GtkWidget *widget,
|
|||
}
|
||||
else
|
||||
{
|
||||
gdk_window_raise (dialog->palette_select->shell->window);
|
||||
gtk_window_present (GTK_WINDOW (dialog->palette_select));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -126,14 +126,7 @@ palette_import_dialog_show (Gimp *gimp)
|
|||
if (! the_import_dialog)
|
||||
the_import_dialog = palette_import_dialog_new (gimp);
|
||||
|
||||
if (! GTK_WIDGET_VISIBLE (the_import_dialog->dialog))
|
||||
{
|
||||
gtk_widget_show (the_import_dialog->dialog);
|
||||
}
|
||||
else if (the_import_dialog->dialog->window)
|
||||
{
|
||||
gdk_window_raise (the_import_dialog->dialog->window);
|
||||
}
|
||||
gtk_window_present (GTK_WINDOW (the_import_dialog->dialog));
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
@ -2498,7 +2498,7 @@ gimp_display_shell_close_warning_dialog (GimpDisplayShell *shell,
|
|||
|
||||
if (shell->warning_dialog)
|
||||
{
|
||||
gdk_window_raise (shell->warning_dialog->window);
|
||||
gtk_window_present (GTK_WINDOW (shell->warning_dialog));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -2498,7 +2498,7 @@ gimp_display_shell_close_warning_dialog (GimpDisplayShell *shell,
|
|||
|
||||
if (shell->warning_dialog)
|
||||
{
|
||||
gdk_window_raise (shell->warning_dialog->window);
|
||||
gtk_window_present (GTK_WINDOW (shell->warning_dialog));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -255,8 +255,6 @@ about_dialog_create (void)
|
|||
|
||||
if (! GTK_WIDGET_VISIBLE (about_dialog))
|
||||
{
|
||||
gtk_widget_show (about_dialog);
|
||||
|
||||
do_animation = TRUE;
|
||||
do_scrolling = FALSE;
|
||||
scroll_state = 0;
|
||||
|
@ -291,10 +289,8 @@ about_dialog_create (void)
|
|||
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gdk_window_raise (about_dialog->window);
|
||||
}
|
||||
|
||||
gtk_window_present (GTK_WINDOW (about_dialog));
|
||||
|
||||
return about_dialog;
|
||||
}
|
||||
|
|
|
@ -541,6 +541,6 @@ indexed_custom_palette_button_callback (GtkWidget *widget,
|
|||
}
|
||||
else
|
||||
{
|
||||
gdk_window_raise (dialog->palette_select->shell->window);
|
||||
gtk_window_present (GTK_WINDOW (dialog->palette_select));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -392,11 +392,7 @@ dialogs_show_toolbox (void)
|
|||
{
|
||||
if (GTK_WIDGET_TOPLEVEL (list->data))
|
||||
{
|
||||
if (GTK_WIDGET_VISIBLE (list->data))
|
||||
gtk_widget_show (GTK_WIDGET (list->data));
|
||||
else
|
||||
gdk_window_raise (GTK_WIDGET (list->data)->window);
|
||||
|
||||
gtk_window_present (GTK_WINDOW (list->data));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -217,7 +217,7 @@ file_revert_cmd_callback (GtkWidget *widget,
|
|||
}
|
||||
else if (query_box)
|
||||
{
|
||||
gdk_window_raise (query_box->window);
|
||||
gtk_window_present (GTK_WINDOW (query_box->window));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -126,14 +126,7 @@ palette_import_dialog_show (Gimp *gimp)
|
|||
if (! the_import_dialog)
|
||||
the_import_dialog = palette_import_dialog_new (gimp);
|
||||
|
||||
if (! GTK_WIDGET_VISIBLE (the_import_dialog->dialog))
|
||||
{
|
||||
gtk_widget_show (the_import_dialog->dialog);
|
||||
}
|
||||
else if (the_import_dialog->dialog->window)
|
||||
{
|
||||
gdk_window_raise (the_import_dialog->dialog->window);
|
||||
}
|
||||
gtk_window_present (GTK_WINDOW (the_import_dialog->dialog));
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
@ -556,9 +556,7 @@ text_tool_editor (GimpTextTool *text_tool)
|
|||
|
||||
if (text_tool->editor)
|
||||
{
|
||||
if (text_tool->editor->window)
|
||||
gdk_window_raise (text_tool->editor->window);
|
||||
|
||||
gtk_window_present (GTK_WINDOW (text_tool->editor));
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -627,9 +625,7 @@ text_tool_editor_load (GtkWidget *widget,
|
|||
|
||||
if (text_tool->filesel)
|
||||
{
|
||||
if (text_tool->filesel->window)
|
||||
gdk_window_raise (text_tool->filesel->window);
|
||||
|
||||
gtk_window_present (GTK_WINDOW (text_tool->filesel));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -499,10 +499,7 @@ gimp_dialog_factory_dialog_new_internal (GimpDialogFactory *factory,
|
|||
{
|
||||
if (GTK_WIDGET_TOPLEVEL (dialog))
|
||||
{
|
||||
if (! GTK_WIDGET_VISIBLE (dialog))
|
||||
gtk_widget_show (dialog);
|
||||
else if (dialog->window)
|
||||
gdk_window_raise (dialog->window);
|
||||
gtk_window_present (GTK_WINDOW (dialog));
|
||||
}
|
||||
else if (GIMP_IS_DOCKABLE (dialog))
|
||||
{
|
||||
|
@ -526,10 +523,7 @@ gimp_dialog_factory_dialog_new_internal (GimpDialogFactory *factory,
|
|||
|
||||
toplevel = gtk_widget_get_toplevel (dialog);
|
||||
|
||||
if (! GTK_WIDGET_VISIBLE (toplevel))
|
||||
gtk_widget_show (toplevel);
|
||||
else if (toplevel->window)
|
||||
gdk_window_raise (toplevel->window);
|
||||
gtk_window_present (GTK_WINDOW (toplevel));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -254,7 +254,7 @@ gimp_document_view_raise_display (gpointer data,
|
|||
if (uri && ! strcmp (closure->name, uri))
|
||||
{
|
||||
closure->found = TRUE;
|
||||
gdk_window_raise (gdisp->shell->window);
|
||||
gtk_window_present (GTK_WINDOW (gdisp->shell));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -96,7 +96,6 @@ gimp_message_box (const gchar *message,
|
|||
msg_box->repeat_count);
|
||||
gtk_label_set_text (GTK_LABEL (msg_box->repeat_label), text);
|
||||
g_free (text);
|
||||
gdk_window_raise (msg_box->mbox->window);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -109,9 +108,9 @@ gimp_message_box (const gchar *message,
|
|||
gtk_widget_show (label);
|
||||
|
||||
msg_box->repeat_label = label;
|
||||
gdk_window_raise (msg_box->mbox->window);
|
||||
}
|
||||
|
||||
gtk_window_present (GTK_WINDOW (msg_box->mbox));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -402,10 +402,7 @@ gimp_file_selection_browse_callback (GtkWidget *widget,
|
|||
gtk_file_selection_set_filename (GTK_FILE_SELECTION (gfs->file_selection),
|
||||
filename);
|
||||
|
||||
if (! GTK_WIDGET_VISIBLE (gfs->file_selection))
|
||||
gtk_widget_show (gfs->file_selection);
|
||||
else
|
||||
gdk_window_raise (gfs->file_selection->window);
|
||||
gtk_window_present (GTK_WINDOW (gfs->file_selection));
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -402,10 +402,7 @@ gimp_file_selection_browse_callback (GtkWidget *widget,
|
|||
gtk_file_selection_set_filename (GTK_FILE_SELECTION (gfs->file_selection),
|
||||
filename);
|
||||
|
||||
if (! GTK_WIDGET_VISIBLE (gfs->file_selection))
|
||||
gtk_widget_show (gfs->file_selection);
|
||||
else
|
||||
gdk_window_raise (gfs->file_selection->window);
|
||||
gtk_window_present (GTK_WINDOW (gfs->file_selection));
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -1384,7 +1384,7 @@ explorer_logo_dialog (void)
|
|||
|
||||
if (logodlg)
|
||||
{
|
||||
gdk_window_raise (logodlg->window);
|
||||
gtk_window_present (GTK_WINDOW (logodlg));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -1453,7 +1453,7 @@ fractalexplorer_rescan_list (void)
|
|||
|
||||
if (dlg)
|
||||
{
|
||||
gdk_window_raise (dlg->window);
|
||||
gtk_window_present (GTK_WINDOW (dlg));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -1727,7 +1727,6 @@ alienmap_logo_dialog (void)
|
|||
}
|
||||
else
|
||||
{
|
||||
gtk_widget_show (logodlg);
|
||||
gdk_window_raise (logodlg->window);
|
||||
gtk_window_present (GTK_WINDOW (logodlg));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1734,7 +1734,6 @@ alienmap2_logo_dialog (void)
|
|||
}
|
||||
else
|
||||
{
|
||||
gtk_widget_show (logodlg);
|
||||
gdk_window_raise (logodlg->window);
|
||||
gtk_window_present (GTK_WINDOW (logodlg));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2081,11 +2081,11 @@ void selectcolor1(vector *col)
|
|||
|
||||
if(!t) return;
|
||||
|
||||
if(window) {
|
||||
gtk_widget_show(window);
|
||||
gdk_window_raise(window->window);
|
||||
return;
|
||||
}
|
||||
if (window)
|
||||
{
|
||||
gtk_window_present (GTK_WINDOW (window));
|
||||
return;
|
||||
}
|
||||
|
||||
window = gtk_color_selection_dialog_new( _("Color Selection Dialog"));
|
||||
|
||||
|
@ -2119,11 +2119,11 @@ void selectcolor2(vector *col)
|
|||
|
||||
if(!t) return;
|
||||
|
||||
if(window) {
|
||||
gtk_widget_show(window);
|
||||
gdk_window_raise(window->window);
|
||||
return;
|
||||
}
|
||||
if (window)
|
||||
{
|
||||
gtk_window_present (GTK_WINDOW (window));
|
||||
return;
|
||||
}
|
||||
|
||||
window = gtk_color_selection_dialog_new( _("Color Selection Dialog"));
|
||||
|
||||
|
|
|
@ -747,17 +747,14 @@ edit_callback (GtkWidget *widget,
|
|||
|
||||
set_edit_preview ();
|
||||
|
||||
if (!GTK_WIDGET_VISIBLE (edit_dlg))
|
||||
gtk_widget_show (edit_dlg);
|
||||
else
|
||||
gdk_window_raise (edit_dlg->window);
|
||||
gtk_window_present (GTK_WINDOW (edit_dlg));
|
||||
}
|
||||
|
||||
static void
|
||||
load_callback (GtkWidget *widget,
|
||||
gpointer data)
|
||||
{
|
||||
if (!file_dlg)
|
||||
if (! file_dlg)
|
||||
{
|
||||
make_file_dlg ();
|
||||
}
|
||||
|
@ -765,7 +762,7 @@ load_callback (GtkWidget *widget,
|
|||
{
|
||||
if (GTK_WIDGET_VISIBLE (file_dlg))
|
||||
{
|
||||
gdk_window_raise (file_dlg->window);
|
||||
gtk_window_present (GTK_WINDOW (file_dlg));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -787,7 +784,7 @@ save_callback (GtkWidget *widget,
|
|||
{
|
||||
if (GTK_WIDGET_VISIBLE (file_dlg))
|
||||
{
|
||||
gdk_window_raise (file_dlg->window);
|
||||
gtk_window_present (GTK_WINDOW (file_dlg));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1994,7 +1994,7 @@ bezier_dialog (void)
|
|||
|
||||
if (window)
|
||||
{
|
||||
gdk_window_raise (window->window);
|
||||
gtk_window_present (GTK_WINDOW (window));
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -4501,7 +4501,7 @@ gfig_rescan_list (void)
|
|||
|
||||
if (dlg)
|
||||
{
|
||||
gdk_window_raise (dlg->window);
|
||||
gtk_window_present (GTK_WINDOW (dlg));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -92,11 +92,11 @@ void selectcolor(void)
|
|||
static GtkWidget *window = NULL;
|
||||
gdouble tmpcol[3];
|
||||
|
||||
if(window) {
|
||||
gtk_widget_show(window);
|
||||
gdk_window_raise(window->window);
|
||||
return;
|
||||
}
|
||||
if (window)
|
||||
{
|
||||
gtk_window_present (GTK_WINDOW (window));
|
||||
return;
|
||||
}
|
||||
|
||||
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(generalbgradio[0]), TRUE);
|
||||
|
||||
|
|
|
@ -337,11 +337,12 @@ void showabout(void)
|
|||
GtkWidget *logobox, *tmpframe;
|
||||
int y;
|
||||
|
||||
if(window) {
|
||||
gtk_widget_show(window);
|
||||
gdk_window_raise(window->window);
|
||||
return;
|
||||
}
|
||||
if (window)
|
||||
{
|
||||
gtk_window_present (GTK_WINDOW (window));
|
||||
return;
|
||||
}
|
||||
|
||||
window = gtk_dialog_new ();
|
||||
gtk_window_set_title (GTK_WINDOW (window), _("The GIMPressionist!"));
|
||||
gtk_window_set_position (GTK_WINDOW (window), GTK_WIN_POS_MOUSE);
|
||||
|
|
Loading…
Reference in New Issue