Closed Bug 387386 Opened 13 years ago Closed 13 years ago

Customize toolbar dialog-overlay not being initialized on first use

Categories

(Calendar :: Lightning Only, defect)

defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: giermann, Assigned: michael.buettner)

Details

(Whiteboard: [patch in hand])

Attachments

(1 file, 1 obsolete file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.1.4) Gecko/20070515 Firefox/2.0.0.4
Build Identifier: 

The new Lightning outfit overlays the customize toolbar dialog to customize the new mode-toolbar.
This one unfortunately is not beeing initialized well, when no customizations have been done before.

Reproducible: Always




I collected several steps to display the strange behaviour.
To reproduce, always close TB and delete 'localstore.rdf' to re-start TB with "clean" default:

1. Wrong selection in 'Show:' Drop-down of mode-toolbar customization
1.a)
- default display of 'mode-toolbar' is 'Icons and text'
- right click on mode-toolbar / Customize...:
  'Show: Icons' is displayed, which is wrong

1.b)
- right click on mail-toolbar / Customize... /
  select 'Show: Text' and press [OK]
- right click on mail-toolbar / Customize... /
  select 'Toolbar: mode-toolbar':
  'Show: Text' is still being displayed, which is also wrong

If this setting is changed once, the correct setting is being displayed. But it is annoying, that you have to select something else first, to switch to 'Show: Icon', because this is being selected already...


2. Location of 'mode-toolbar' is not being changed immediately
2.a)
- Customize 'mode-toolbar': 'Location: bottom' is displayed, which is correct
- switch to 'Location: top' - nothing happens
- restart TB: mode-toolbar appears on top

(remember to remove 'localstore.rdf' before each reproduce...)
2.b)
- Customize 'mode-toolbar': 'Location: bottom' is displayed, which is correct
- switch to 'Location: top' - nothing happens
- switch to 'Location: bottom' - nothing happens, as it is still there ;-)
- switch to 'Location: top' - bar appears on top

2.c)
- Customize 'mode-toolbar': 'Location: bottom' is displayed, press [Cancel]
- switch to 'Location: top' - bar appears on top

So I guess something is being initialized by just displaying the dialog (as [Cancel] does not store anything).

As I do not understand the customize code in detail, it's time for mickey to fix this bug...
Another one for me. Sven, thanks for the detailed steps in order to reproduce this bug.
Assignee: nobody → michael.buettner
Status: UNCONFIRMED → NEW
Ever confirmed: true
Flags: blocking-calendar0.7+
Attached patch patch v1 (obsolete) — Splinter Review
The description above actually revealed that there were two different bugs in the customize toolbar dialog for the mode toolbar. This patch fixes both issues.

The first one is that the toolbar mode (full, icons or text) isn't specified. I just forgot to specify the initial mode at the mode toolbox. I'm not entirely sure why I need to repeat the attribute at the toolbar in order to make this work as expected. Philipp, probably you can shed some light in here...

Second, the initial location switch from bottom to top didn't work due to a totally stupid if-condition.
Attachment #277575 - Flags: review?(philipp)
Whiteboard: [patch in hand]
Verified this patch is working with TB 1.5.0.9 and Lightning 2007-08-21.

Mickey: For me the mode="full" for the toolbox is sufficient in TB 1.5 - maybe the problem was introduced in TB2 (did not check this)?
Attached patch patch v2Splinter Review
Indeed adding the mode attribute to the toolbar was superfluous, this is the up to date version of the patch.
Attachment #277575 - Attachment is obsolete: true
Attachment #278735 - Flags: review?(philipp)
Attachment #277575 - Flags: review?(philipp)
Comment on attachment 278735 [details] [diff] [review]
patch v2

r=philipp

You could optionally add a blank for the "if" and to improve readability, add brackets around the OR condition, but I'm fine without since the rest of this file is also not styled right.
Attachment #278735 - Flags: review?(philipp) → review+
patch checked in on trunk and MOZILLA_1_8_BRANCH

-> FIXED
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → 0.7
verified with lightning 2007083103
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.