Last Comment Bug 768768 - Launch app from shell, close, then launch it from terminal results in no icon showing up in task bar in ubuntu
: Launch app from shell, close, then launch it from terminal results in no icon...
Status: VERIFIED FIXED
[qa!]
: regression
Product: Firefox Graveyard
Classification: Graveyard
Component: Webapp Runtime (show other bugs)
: unspecified
: All Linux
: P3 normal
: Firefox 16
Assigned To: Nobody; OK to take it and work on it
: Jason Smith [:jsmith]
Mentors:
Depends on:
Blocks: 762641 763358
  Show dependency treegraph
 
Reported: 2012-06-26 21:39 PDT by Jason Smith [:jsmith]
Modified: 2016-03-21 12:39 PDT (History)
4 users (show)
See Also:
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
use g_set_prgname (1.09 KB, patch)
2012-06-29 03:27 PDT, Marco Castelluccio [:marco]
karlt: review+
myk: checkin+
Details | Diff | Splinter Review

Description Jason Smith [:jsmith] 2012-06-26 21:39:10 PDT
Regression from bug 763358.

Steps from bug 762641:

1) Launch a webapp from the shell (ie, the dash or launcher in unity or the activities overlay in gnome shell)
2) Close the webapp and then launch it from a terminal window (ie, ~/.http\;www.lordofultima.com/webapprt-stub)

Expected:

App launches with correct app icon.

Actual:

App launches without an app icon.

Additional Notes:

See https://bugzilla.mozilla.org/show_bug.cgi?id=762641#c13
Comment 1 Karl Tomlinson (:karlt) 2012-06-26 21:57:39 PDT
Thanks, Jason.

Chris, was there a reason to choose gdk_set_program_class over g_set_prgname?

g_set_prgname would also set the name class hint, which is the "formal name of the application that should be used when retrieving the application's resources from the resource database", but it's hard to guess the modern effects of these ancient properties.
Comment 2 Karl Tomlinson (:karlt) 2012-06-26 22:10:11 PDT
Often the name field of the class hint gets overridden by a windowtype attribute of the XUL window anyway, so perhaps it's more a question of whether the binary name or the app name is more suitable for GLib, if it matters.
Comment 3 Chris Coulson 2012-06-27 17:23:07 PDT
There wasn't really any particular reason for choosing gdk_set_program_class over g_set_prgname, other than the former being a more direct way of achieving the same result. g_set_prgname should work too, but I want to have a quick look in glib at where this names is used, just to make sure it doesn't break anything else.
Comment 4 Marco Castelluccio [:marco] 2012-06-29 03:27:19 PDT
Created attachment 637826 [details] [diff] [review]
use g_set_prgname

Looks like this fixes the problem.
However sometimes when you launch an application from the terminal, for a second you get two icons on the Launcher.
Comment 5 Chris Coulson 2012-06-29 03:57:05 PDT
Yes, g_set_prgname should be fine here. The places it gets used in glib and gtk are either not used by us, or they don't care what the name is (or both)
Comment 6 Myk Melez [:myk] [@mykmelez] 2012-07-13 12:05:20 PDT
Comment on attachment 637826 [details] [diff] [review]
use g_set_prgname

https://hg.mozilla.org/integration/mozilla-inbound/rev/06756c4481d5
Comment 7 Jason Smith [:jsmith] 2012-07-13 17:45:07 PDT
(In reply to Marco Castelluccio from comment #4)
> Created attachment 637826 [details] [diff] [review]
> use g_set_prgname
> 
> Looks like this fixes the problem.
> However sometimes when you launch an application from the terminal, for a
> second you get two icons on the Launcher.

Can you still reproduce this with this patch applied? If so, can you file a bug for this?
Comment 8 Ryan VanderMeulen [:RyanVM] 2012-07-13 20:22:12 PDT
https://hg.mozilla.org/mozilla-central/rev/06756c4481d5
Comment 9 Marco Castelluccio [:marco] 2012-07-14 16:01:39 PDT
(In reply to Jason Smith [:jsmith] from comment #7)
> Can you still reproduce this with this patch applied? If so, can you file a
> bug for this?

Can't reproduce anymore. I'll file a new bug in case this will present again.

Note You need to log in before you can comment on or make changes to this bug.