LOG("reloading\n");
kill_nagbar(&config_error_nagbar_pid, false);
kill_nagbar(&command_error_nagbar_pid, false);
- load_configuration(conn, NULL, true);
+ load_configuration(NULL, C_RELOAD);
x_set_i3_atoms();
/* Send an IPC event just in case the ws names have changed */
ipc_send_workspace_event("reload", NULL, NULL);
*
*/
void cmd_focus_output(I3_CMD, const char *name) {
- owindow *current;
-
- DLOG("name = %s\n", name);
-
HANDLE_EMPTY_MATCH;
- /* get the output */
- Output *current_output = NULL;
- Output *output;
-
- TAILQ_FOREACH(current, &owindows, owindows)
- current_output = get_output_for_con(current->con);
- assert(current_output != NULL);
+ if (TAILQ_EMPTY(&owindows)) {
+ ysuccess(true);
+ return;
+ }
- output = get_output_from_string(current_output, name);
+ Output *current_output = get_output_for_con(TAILQ_FIRST(&owindows)->con);
+ Output *output = get_output_from_string(current_output, name);
if (!output) {
- yerror("No such output found.");
+ yerror("Output %s not found.", name);
return;
}
workspace_show(ws);
cmd_output->needs_tree_render = true;
- // XXX: default reply for now, make this a better reply
ysuccess(true);
}
cmd_output->needs_tree_render = true;
ysuccess(true);
- ewmh_update_desktop_names();
- ewmh_update_desktop_viewport();
- ewmh_update_current_desktop();
+ ewmh_update_desktop_properties();
startup_sequence_rename_workspace(old_name_copy, new_name);
free(old_name_copy);