After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 103240 - 2 "Application" Type to "Create Launcher"
2 "Application" Type to "Create Launcher"
Status: RESOLVED FIXED
Product: gnome-desktop
Classification: Core
Component: general
unspecified
Other other
: Normal normal
: ---
Assigned To: Desktop Maintainers
Desktop Maintainers
Depends on:
Blocks:
 
 
Reported: 2003-01-13 01:56 UTC by Havoc Pennington
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Havoc Pennington 2003-01-13 01:53:33 UTC
Bugzilla-Product: gnome-desktop
Description:

  Please see https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=73284
  for the original bug report.




------- Bug moved to this database by unknown@bugzilla.gnome.org 2003-01-12 20:53 -------

Reassigning to the default owner of the component, gnome-desktop-maint@bugzilla.gnome.org.

Comment 1 Kalle Olavi Niemitalo 2003-03-10 17:44:30 UTC
Forwarded from http://bugs.debian.org/184109

Package: libgnome-desktop-2
Version: 2.2.0.1-1
Severity: minor

Click an empty part of a panel with mouse button 3 and choose 
"Add to Panel"->"Laucher...".  The "Create Launcher" dialog 
opens.  In this dialog, there is a "Type" drop-down list with 
items "Application", "Directory", "Link", "FSDevice", "MIME 
Type", "Service" and "ServiceType".

Enter the following data: Name="No name", Type="Link", 
URL="file:///", Icon="/usr/share/pixmaps/apple-red.png".  
Click OK.  A launcher appears in the panel.

Click the new launcher with mouse button 3 and choose 
"Properties".  The "Launcher Properties" dialog opens.  In this 
dialog, there is a "Type" drop-down list with the same items as 
before, except there is an additional "Link" at the bottom.  That 
should not be there.

I believe the bug is in the function setup_option() in 
gnome-desktop-2.2.0.1/libgnome-desktop/gnome-ditem-edit.c.  
This function first sets up the usual items in the drop-down 
list, and then does the following:

	if (select && selected)
		add_menuitem (menu, select, _(select), select, &selected);

(select) is either NULL or a string taken from the current state 
of the GnomeDesktopItem.  If setup_option() has added an item 
that matches (select), then (selected) points to that item; 
otherwise, (selected) is NULL.  Thus, the statement quoted above 
adds an extra item whenever the current value is among the 
normal items.  The proper check would be if (select && !selected), 
so that the current value would be inserted as an extra item only 
if the normal items don't cover it already.

In GNOME CVS, this bug was introduced in revision 1.62 of 
gnome-desktop/libgnome-desktop/gnome-ditem-edit.c when Mark 
McLoughlin reformatted some code while applying Arvind Samptur's 
patch to GNOME bug #85782.
Comment 2 Mark McLoughlin 2003-03-10 19:32:41 UTC
Thanks for tracking this down - I'm a doofus :/

Fixed in CVS:


2003-03-11  Mark McLoughlin  <mark@skynet.ie>
                                                                     
                                       
        * gnome-ditem-edit.c: (setup_option): fix blooper I made
        when committing a patch from Arvind. Tracked down by
        Kalle Olavi Niemitalo in bug #130240.