If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

need better mechanism for switching view-mode in tbird

RESOLVED FIXED in Lightning 0.1

Status

Calendar
Lightning Only
P3
normal
RESOLVED FIXED
13 years ago
12 years ago

People

(Reporter: shaver, Assigned: Joey Minta)

Tracking

unspecified
Lightning 0.1

Details

Attachments

(1 attachment)

We need to do things like:

- disable a handful of mail-related menu items (view->{headers,sort by,etc.})

- figure out the toolbar (do we need a second one to swap in?)

- make going back to "mail mode" restore the proper folder/server view

Maybe we want to make clicking on the minimonth do that switch to calendar, and
make sure that the folder pane always moves us back to mail.

Comment 1

13 years ago
I've noticed that after switching from Classical View to another view, switching
back does not enabled Classical View. I'm using
http://ftp.mozilla.org/pub/mozilla.org/calendar/lightning/contrib/lightning-win32-20050601.xpi
with Thunderbird version 1.0+ (20050601)
Do you see anything in the JS console?  Does it behave differently if you don't
have Lightning installed?

Comment 3

13 years ago
Without Lightning Thunderbird does not behave this way.
After doing some more research, it seems this bug does not occur only with
Classic View but also with other views, but not always...
The JS console gives 2 error messages when switching once between Classical and
Wide:

Error: gDBView has no properties
Source File: chrome://messenger/content/msgMail3PaneWindow.js
Line: 1574

and
Error: gDBView has no properties
Source File: chrome://messenger/content/mailWindowOverlay.js
Line: 192

When switching several times between all views, I get additional errors:

Error: [Exception... "Component returned failure code: 0x80570016
(NS_ERROR_XPC_GS_RETURNED_FAILURE) [nsIJSCID.getService]"  nsresult: "0x80570016
(NS_ERROR_XPC_GS_RETURNED_FAILURE)"  location: "JS frame ::
file:///C:/Documents%20and%20Settings/Dexter/Application%20Data/Thunderbird/Profiles/t6xq2qbv.Default%20User/extensions/%7Be2fda1a4-762b-4020-b5ad-a41df1933103%7D/components/calCompositeCalendar.js
:: anonymous :: line 142"  data: no]
Source File:
file:///C:/Documents%20and%20Settings/Dexter/Application%20Data/Thunderbird/Profiles/t6xq2qbv.Default%20User/extensions/%7Be2fda1a4-762b-4020-b5ad-a41df1933103%7D/components/calCompositeCalendar.js
Line: 142

Error: [Exception... "Invalid ClassID or ContractID"  nsresult: "0x80570017
(NS_ERROR_XPC_BAD_CID)"  location: "JS frame ::
file:///C:/Documents%20and%20Settings/Dexter/Application%20Data/Thunderbird/Profiles/t6xq2qbv.Default%20User/extensions/%7Be2fda1a4-762b-4020-b5ad-a41df1933103%7D/components/calItemModule.js
:: initBaseComponent :: line 63"  data: no]
Source File:
file:///C:/Documents%20and%20Settings/Dexter/Application%20Data/Thunderbird/Profiles/t6xq2qbv.Default%20User/extensions/%7Be2fda1a4-762b-4020-b5ad-a41df1933103%7D/components/calItemModule.js
Line: 63

Error: [Exception... "Component returned failure code: 0x80570016
(NS_ERROR_XPC_GS_RETURNED_FAILURE) [nsIJSCID.getService]"  nsresult: "0x80570016
(NS_ERROR_XPC_GS_RETURNED_FAILURE)"  location: "JS frame ::
chrome://lightning/content/lightning-utils.js :: ltnGetService :: line 11" 
data: no]
Source File: chrome://lightning/content/lightning-utils.js
Line: 11

Error: redeclaration of const imgICache
Source File: chrome://communicator/content/contentAreaUtils.js
Line: 230

Error: redeclaration of const kMailToLength
Source File: chrome://communicator/content/nsContextMenu.js
Line: 13

Error: uncaught exception: [Exception... "Invalid ClassID or ContractID" 
nsresult: "0x80570017 (NS_ERROR_XPC_BAD_CID)"  location: "JS frame ::
chrome://lightning/content/lightning-utils.js :: <TOP_LEVEL> :: line 24"  data: no]

Error: uncaught exception: [Exception... "Invalid ClassID or ContractID" 
nsresult: "0x80570017 (NS_ERROR_XPC_BAD_CID)"  location: "JS frame ::
chrome://calendar/content/calendarUtils.js :: <TOP_LEVEL> :: line 92"  data: no]

Maybe I should file a new bug for this?

Comment 4

13 years ago
This occurs with a fresh Thunderbird profile and installation
Ugh, yes, you absolutely should; this has nothing to do with the stuff
summarized in the Description.  (I wish I'd noticed what bug I was in before I
prolonged the conversation. =/)
Blocks: 298366

Updated

12 years ago
Priority: -- → P3

Updated

12 years ago
Target Milestone: --- → Lightning 0.8
(Assignee)

Comment 6

12 years ago
*** Bug 316792 has been marked as a duplicate of this bug. ***

Comment 7

12 years ago
Here's a possible solution (a toggle):

+-----------------+---------------------------------------------------
| Mail Folders  \/|    <--- Click (anywhere) here, to get...
| +-----------------+
| | Mail Folders    |  <--- dropdown to select/toggle mail & calendar
| | Calendar        |
| +-----------------+
|  [] Templates   |
|  [] Sent        |
|  ...            |
+-----------------+---------------------------------------------------

Although that might be too "hidden" for normal users. Better might be a "vertically sliding pane":

+-----------------+---------------------------------------------------
| Mail            |  <--- Click to open Mail (and collapse Calendar)
|-----------------|
| Account 1       |
|  [] Inbox       |
|  [] Templates   |
|  [] Sent        |
| Local Folders   |
|  ...            |
|-----------------|
| Calendar        |  <--- Click to open Calendar (and collapse mail)
+-----------------+---------------------------------------------------

Comment 8

12 years ago
Opening Calendar would result in this:

+-----------------+---------------------------------------------------
| Mail            |  <--- Click to open Mail (and collapse Calendar)
|-----------------|
| Calendar        |
|-----------------|
|  M T W T F S S  |
|  1 2 3 4 5 6 7  |
|  8 9 1011121314 |
|  ...            |
|-----------------|
| ToDo            |
| [x] Get more sle|
+-----------------+---------------------------------------------------
(Assignee)

Comment 9

12 years ago
Created attachment 205450 [details] [diff] [review]
remove folderTree selection

This ended up being a lot harder than I thought.  Thunderbird's FolderPaneSelectionChange function includes a ton of checks with internal global variables to determine whether or not to actually redraw the message-list.  Removing the selection, and the associated variables, seemed to me to be the best way to force this redraw to happen.

The main problem with the seemingly simpler 'onclick' handler approach it figuring out whether or not TB is going to handle the click on its own or not.  Rather than trying to keep pace with changes in thunderbird code, the above approach simply ensures that TB will always respond to the click.
Assignee: shaver → jminta
Status: NEW → ASSIGNED
Attachment #205450 - Flags: first-review?(dmose)
OK, I think is bug is really a mish-mash of a whole bunch of issues:

a) what sort of toolbar UI do we want?

b) need to disable/enabled mail-related items when switching modes

c) in calendar mode, if you click on the already-selected mail folder, nothing happens (we should switch back to mail mode)

d) in calendar mode, if you click on an empty area of the folder pane, nothing happens (we should switch back to the selected folder in mail mode)

e) do we need additional UI to switch between calendar and mail modes?

I think we need 5 separate bugs.  I propose this bug be used to track c), since we've already got a patch here that addresses it. Also, I think c) is probably the only Lightning 0.1 blocker out of those five.
OK, I talked this over with Joey, and we're going to go with separate bugs.  If anyone is interested in doing the work to spin out those separate bugs, that'd rock.
Comment on attachment 205450 [details] [diff] [review]
remove folderTree selection

r=dmose.  I think this is good enough for 0.1.  For the longer term, I'd like to either keep this bug open or open a new one so that this eventually gets fixed in a way that doesn't involved unnecessarily reloading the folder.
Attachment #205450 - Flags: first-review?(dmose) → first-review+
(Assignee)

Comment 13

12 years ago
Patch checked in.  Removing the 0.1 block, but I'll leave this bug open until someone has the time to get the separate bugs filed.
No longer blocks: 298366

Updated

12 years ago
QA Contact: shaver → lightning
(Assignee)

Comment 14

12 years ago
(In reply to comment #10)
> a) what sort of toolbar UI do we want?
Bug 327780
> 
> b) need to disable/enabled mail-related items when switching modes
Bug 327737
> 
> c) in calendar mode, if you click on the already-selected mail folder, nothing
> happens (we should switch back to mail mode)
Fixed by the patch here already.
> 
> d) in calendar mode, if you click on an empty area of the folder pane, nothing
> happens (we should switch back to the selected folder in mail mode)
Bug 327781
> 
> e) do we need additional UI to switch between calendar and mail modes?
Bug 327783

Closing bug as a result of finally completing these additional filings.
Status: ASSIGNED → RESOLVED
Last Resolved: 12 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.