Commit 6913c628 authored by Luis de Bethencourt's avatar Luis de Bethencourt

ui: when loading empty notify user of how to add content

parent a0ced4a1
......@@ -785,6 +785,9 @@ engine_load_uri (GstEngine * engine, gchar * uri)
g_print ("Loading: %s\n", uri);
g_object_set (G_OBJECT (engine->player), "uri", uri, NULL);
} else {
g_print ("No media set. %s\n",
"You can drag and drop a file into snappy to play it.");
}
return;
......
......@@ -498,6 +498,10 @@ load_controls (UserInterface * ui)
// Controls title
ui->control_title = clutter_text_new_full ("Sans 32px",
cut_long_filename (ui->filename, ui->title_length), &control_color2);
if (strcmp (ui->filename, "") == 0) {
clutter_text_set_text (CLUTTER_TEXT (ui->control_title),
"Drag and drop a file here to play it");
}
clutter_text_set_max_length (CLUTTER_TEXT (ui->control_title),
ui->title_length);
clutter_box_layout_pack (CLUTTER_BOX_LAYOUT (ui->main_box_layout), ui->control_title, TRUE, /* expand */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment