Closed
Bug 866138
Opened 12 years ago
Closed 11 years ago
Make options panel less hacky
Categories
(DevTools :: Framework, defect)
DevTools
Framework
Tracking
(Not tracked)
RESOLVED
FIXED
Firefox 23
People
(Reporter: Optimizer, Assigned: Optimizer)
References
Details
Attachments
(1 file, 3 obsolete files)
54.32 KB,
patch
|
Details | Diff | Splinter Review |
There are things that can be improved:
1) Try to convert the options panel into a real tool, without creating menu items or global shortcuts. Also not allowing options panel to be disabled via the options panel.
2) Remove the dependency of the disabledTools pref json. Since the killswitches are synced now, we should be directly using them to disable or enable any tool.
Assignee | ||
Comment 1•12 years ago
|
||
This patch:
1) Removes the dependency of the disabledTools json pref and uses the killswitch pref for each tool individually.
2) Converts the options panel into a tool with 0th ordinal. Makes sure that no menu item, shortcut and options panel entry is made for the options tool.
Attachment #744090 -
Flags: review?(jwalker)
Comment 2•12 years ago
|
||
Comment on attachment 744090 [details] [diff] [review]
patch v0.1
Review of attachment 744090 [details] [diff] [review]:
-----------------------------------------------------------------
We need to change how we use killswitches, right?
Attachment #744090 -
Flags: review?(jwalker)
Assignee | ||
Comment 3•12 years ago
|
||
(In reply to Joe Walker [:jwalker] from comment #2)
> Comment on attachment 744090 [details] [diff] [review]
> patch v0.1
>
> Review of attachment 744090 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> We need to change how we use killswitches, right?
bug 867397 suggests that we change the meaning of killswitches to visibility switches. As per the current logic, that would mean just a rename of a variable from killswitch to visibilityswitch.
I can do that in this patch also, if it is decided for final.
Comment 4•12 years ago
|
||
Comment on attachment 744090 [details] [diff] [review]
patch v0.1
Review of attachment 744090 [details] [diff] [review]:
-----------------------------------------------------------------
It looks a bit like toolbox-options.js has DOS line endings (at least it does on my system), please could you check that it doesn't any more.
It's up to you if you'd like to rename the variable here (and make bug 867397 depend on this), or as a patch to bug 867397.
Attachment #744090 -
Flags: review+
Assignee | ||
Comment 5•12 years ago
|
||
Changed the variable name. Changes the inline docs explaining the variable. Removes the passed killswitch in "tool-unregistered" event.
Now that I do not need the pref, we can simply go with passing the tool id in the gDevTools.unregisterTool method. But I did not make that change as it does not harm to have both the options.
Did this try that was green : https://tbpl.mozilla.org/?tree=Try&rev=c8b093ab9dc4
Only the killswitch variable name changed after the try, and all tests pass locally.
Attachment #744090 -
Attachment is obsolete: true
Attachment #745287 -
Flags: review?(jwalker)
Assignee | ||
Comment 6•12 years ago
|
||
Fixed a type in toolUnregistered method.
Attachment #745287 -
Attachment is obsolete: true
Attachment #745287 -
Flags: review?(jwalker)
Attachment #745497 -
Flags: review?(jwalker)
Updated•12 years ago
|
Attachment #745497 -
Flags: review?(jwalker) → review+
Assignee | ||
Updated•12 years ago
|
Whiteboard: [land-in-fx-team]
Comment 7•12 years ago
|
||
Rebased.
I also took the liberty of putting the tools in ordinal order in main.js (was there a good reason to have the debugger and inspector swapped around?
Attachment #745497 -
Attachment is obsolete: true
Assignee | ||
Comment 8•12 years ago
|
||
(In reply to Joe Walker [:jwalker] from comment #7)
> Created attachment 746989 [details] [diff] [review]
> patch v0.4
>
> Rebased.
>
> I also took the liberty of putting the tools in ordinal order in main.js
> (was there a good reason to have the debugger and inspector swapped around?
No idea :)
Comment 9•12 years ago
|
||
Green on try: https://tbpl.mozilla.org/?tree=Try&rev=7ac21da57bbe
Comment 10•12 years ago
|
||
https://tbpl.mozilla.org/?tree=Fx-Team&rev=9ae9cc383d0f
https://hg.mozilla.org/integration/fx-team/rev/9ae9cc383d0f
Whiteboard: [land-in-fx-team] → [fixed-in-fx-team]
Comment 11•11 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 23
Comment 12•11 years ago
|
||
Comment on attachment 746989 [details] [diff] [review]
patch v0.4
>-#toolbox-tab-options {
>- list-style-image: url("chrome://browser/skin/devtools/option-icon.png");
>- -moz-image-region: rect(0px 16px 16px 0px);
>-}
Should have remove that .png from jar.mn and the repository as well, I guess. ;-)
Comment 13•11 years ago
|
||
(In reply to Robert Kaiser (:kairo@mozilla.com) from comment #12)
> Should have remove that .png from jar.mn and the repository as well, I
> guess. ;-)
It's used in .devtools-option-toolbarbutton from devtools common.css.
Comment 14•11 years ago
|
||
(In reply to Victor Porof [:vp] from comment #13)
> It's used in .devtools-option-toolbarbutton from devtools common.css.
Yes, sorry, just figured that out myself. Should look deeper before saying such things.
Updated•6 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•