Tidy up picker code in file-utils.js in cZ
Categories
(SeaMonkey :: Chat, enhancement)
Tracking
(seamonkey2.53+ fixed)
People
(Reporter: iannbugzilla, Assigned: iannbugzilla)
Details
(Whiteboard: SM2.53.20)
Attachments
(1 file)
5.99 KB,
patch
|
frg
:
review+
frg
:
approval-comm-release+
|
Details | Diff | Splinter Review |
At the moment:
- getPicker gets passed an object as an argument but only uses one of the properties of that object
- pickSaveAs has 5 possible arguments but only ever gets called with at most 3 of them
- pickOpen has 4 possible arguments but only ever gets called with at most 2 of them
Tidy up involves:
- setting a null default for futils.lastSaveAsDir and futils.lastOpenDir so the code doesn't have to check for their existence.
- removing MSG_SAVE_AS and MSG_OPEN fallbacks, as a title is always passed through as an argument.
- dropping the object argument from getPicker instead passing the only used property (defaultString) as an argument.
- removing the 2 unused arguments from pickSaveAs and pickOpen.
[Approval Request Comment]
Regression caused by (bug #): n/a
User impact if declined: none
Testing completed (on m-c, etc.): 2.53.20pre
Risk to taking this patch (and alternatives if risky): low
String changes made by this patch: none
![]() |
||
Updated•11 months ago
|
![]() |
||
Comment 2•11 months ago
|
||
Comment on attachment 9438156 [details] [diff] [review]
1931712-irc-file-utils-picker-tidy-25320.patch
lgtm r/a+
![]() |
||
Comment 3•11 months ago
|
||
Btw. https://searchfox.org/comm-central/source/suite/chatzilla/js/lib/file-utils.js#187
picker.show no longer works after Bug 1387800. Still fine for 2.53 but something for the future.
Pushed by frgrahl@gmx.net:
https://hg.mozilla.org/comm-central/rev/3227aaf70906
Tidy up picker code in file-utils.js in cZ. r=frg
![]() |
||
Comment 5•9 months ago
|
||
https://gitlab.com/seamonkey-project/seamonkey-2.53-comm/-/commit/29a3c18a7aa91bfd2954b5bd041ac1d5ea1c0a83
Tidy up picker code in file-utils.js in cZ. r=frg a=frg
Description
•