Remove verbose output on window move

This commit is contained in:
James Booth
2016-09-25 21:47:00 +01:00
parent 72f6b2db71
commit 83974728af
2 changed files with 20 additions and 23 deletions

View File

@@ -5529,8 +5529,7 @@ cmd_titlebar(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_titlebar_pos_up(); gboolean result = prefs_titlebar_pos_up();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Title bar moved up.");
cons_show("");
} else { } else {
cons_show("Could not move title bar up."); cons_show("Could not move title bar up.");
} }
@@ -5541,8 +5540,7 @@ cmd_titlebar(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_titlebar_pos_down(); gboolean result = prefs_titlebar_pos_down();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Title bar moved down.");
cons_show("");
} else { } else {
cons_show("Could not move title bar down."); cons_show("Could not move title bar down.");
} }
@@ -5562,8 +5560,7 @@ cmd_mainwin(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_mainwin_pos_up(); gboolean result = prefs_mainwin_pos_up();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Main window moved up.");
cons_show("");
} else { } else {
cons_show("Could not move main window up."); cons_show("Could not move main window up.");
} }
@@ -5574,8 +5571,7 @@ cmd_mainwin(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_mainwin_pos_down(); gboolean result = prefs_mainwin_pos_down();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Main window moved down.");
cons_show("");
} else { } else {
cons_show("Could not move main window down."); cons_show("Could not move main window down.");
} }
@@ -5595,8 +5591,7 @@ cmd_statusbar(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_statusbar_pos_up(); gboolean result = prefs_statusbar_pos_up();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Status bar moved up");
cons_show("");
} else { } else {
cons_show("Could not move status bar up."); cons_show("Could not move status bar up.");
} }
@@ -5607,8 +5602,7 @@ cmd_statusbar(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_statusbar_pos_down(); gboolean result = prefs_statusbar_pos_down();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Status bar moved down.");
cons_show("");
} else { } else {
cons_show("Could not move status bar down."); cons_show("Could not move status bar down.");
} }
@@ -5628,8 +5622,7 @@ cmd_inputwin(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_inputwin_pos_up(); gboolean result = prefs_inputwin_pos_up();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Input window moved up.");
cons_show("");
} else { } else {
cons_show("Could not move input window up."); cons_show("Could not move input window up.");
} }
@@ -5640,8 +5633,7 @@ cmd_inputwin(ProfWin *window, const char *const command, gchar **args)
gboolean result = prefs_inputwin_pos_down(); gboolean result = prefs_inputwin_pos_down();
if (result) { if (result) {
ui_resize(); ui_resize();
cons_winpos_setting(); cons_show("Input window moved down.");
cons_show("");
} else { } else {
cons_show("Could not move input window down."); cons_show("Could not move input window down.");
} }

View File

@@ -531,13 +531,18 @@ _load_preferences(void)
} }
} }
int titlebar_pos = g_key_file_get_integer(theme, "ui", "titlebar.position", NULL); if (g_key_file_has_key(theme, "ui", "titlebar.position", NULL) &&
int mainwin_pos = g_key_file_get_integer(theme, "ui", "mainwin.position", NULL); g_key_file_has_key(theme, "ui", "mainwin.position", NULL) &&
int statusbar_pos = g_key_file_get_integer(theme, "ui", "statusbar.position", NULL); g_key_file_has_key(theme, "ui", "statusbar.position", NULL) &&
int inputwin_pos = g_key_file_get_integer(theme, "ui", "inputwin.position", NULL); g_key_file_has_key(theme, "ui", "inputwin.position", NULL)) {
ProfWinPlacement *placement = prefs_create_profwin_placement(titlebar_pos, mainwin_pos, statusbar_pos, inputwin_pos); int titlebar_pos = g_key_file_get_integer(theme, "ui", "titlebar.position", NULL);
prefs_save_win_placement(placement); int mainwin_pos = g_key_file_get_integer(theme, "ui", "mainwin.position", NULL);
prefs_free_win_placement(placement); int statusbar_pos = g_key_file_get_integer(theme, "ui", "statusbar.position", NULL);
int inputwin_pos = g_key_file_get_integer(theme, "ui", "inputwin.position", NULL);
ProfWinPlacement *placement = prefs_create_profwin_placement(titlebar_pos, mainwin_pos, statusbar_pos, inputwin_pos);
prefs_save_win_placement(placement);
prefs_free_win_placement(placement);
}
} }
void void