Closed Bug 93487 Opened 23 years ago Closed 23 years ago

need to set default directory in Composer

Categories

(SeaMonkey :: Composer, defect)

x86
Windows NT
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED
mozilla0.9.9

People

(Reporter: mitch, Assigned: cmanske)

References

Details

(Keywords: platform-parity)

Attachments

(1 file, 2 obsolete files)

From Bugzilla Helper: User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.2) Gecko/20010726 Netscape6/6.1 BuildID: Netscape 6.1 PR 1 I dislike not being able to preset a default directory location in Composer. This feature was included in older versions and should be included in this version. Having this feature would make Composer more user friendly. Currently, everytime I want to change a webpage, I must traverse through a stack of directories on the appropriate drive to find the files I want to use. My web page files are kept in a single location. Reproducible: Always Steps to Reproduce: 1. try 2. 3. Actual Results: doesn't save default Expected Results: should
Keywords: nsenterprise
-->editor As a workaround, you might use the "recently edited pages" (under the File menu) if it's for files you regularly edit.
Assignee: kmcclusk → beppe
Component: Compositor → Editor
Keywords: 4xp, pp
QA Contact: petersen → sujay
I don't recall a setting in preferences where you set a default directory on your HD, can you point me to the preference setting?
I agree -- I implemented the feature in 4.7 and liked it very much. It is not a user preference. What I did was remember the last directory you save to in a pref when you save a file, and use that as the initial directory for further file open/saves. Thus if you change the "default directory" via another program or by doing a file open/save from the browser, it doesn't upset the "last used" Composer directory.
Assignee: beppe → cmanske
Target Milestone: --- → mozilla1.0
that is really odd, on win98 when I edit a document and save it in directory C:/foo/bar and then edit another page and select save, that is the directory that is initially displayed. If I close out the app and then do a save, the default directory is the directory location that the app is in. Are you tlaking about across edit sessions, or in the same edit session Charley?
Beth: Are describing behavior in 4.7 or 6.x?
Status: NEW → ASSIGNED
Removing nsenterprise nomination, adding nsBranch.
Keywords: nsenterprisensBranch
Since is targeted for 1.0, marking as nsbranch- for this round.
Keywords: nsbranchnsbranch-
spam composer change
Component: Editor: Core → Editor: Composer
Blocks: 107067
Keywords: nsbranch-
load balancing
Target Milestone: mozilla1.0 → mozilla0.9.8
*** Bug 115806 has been marked as a duplicate of this bug. ***
Attached patch fix (obsolete) — Splinter Review
Notes: editor.js: Set/Get Unichar prefs code was moved to editorUtilities -- these should be used for URL string prefs. Changes in ComposerCommands.js are in nsOpenCommand code and PromptForSaveLocation(), which is used when saving files. General strategy is to save the last-used directory to a pref for each filetype used by Composer. gFilePickerDirectory in the editor window is used to save and reset the current directory used by other modules.
Keywords: patch, review
Whiteboard: FIX IN HAND, need r=,sr=
Comment on attachment 62295 [details] [diff] [review] fix looks ok, r=syd
Attachment #62295 - Flags: review+
Whiteboard: FIX IN HAND, need r=,sr= → FIX IN HAND, need sr=
Comment on attachment 62295 [details] [diff] [review] fix sr=hewitt
Attachment #62295 - Flags: superreview+
checked in
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Whiteboard: FIX IN HAND, need sr=
I don't think this bug was fixed correctly. On Macintosh, we might be pointing to the wrong location (which could be *very* annoying). We shouldn't save the preference as a string but as whatever the equivalent of an nsIFile is (if possible).
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
I don't understand how we can be pointing to the "wrong location". It saves the last location used by the Open File dialog and saves them as UniChar pref strings just as we do for the Recent Files menu. Do you have an example where it doesn't work?
Strings are a "lossy" format on Mac for file locations. That is exactly why we have nsIFile / nsILocalFile. A better fix will use that type of preference instead of a string.
Attached patch Save directory as nsILocalFile (obsolete) — Splinter Review
Previous patch (checked in) was still valid for all callers of Set/SaveSetFilePickerDirectory(). This patch enhances those methods to save pref as nsILocalFile instead of the "file:" URL, as Brade suggested. Kathy: Can you please test this on Mac?
Attachment #62295 - Attachment is obsolete: true
Status: REOPENED → ASSIGNED
Whiteboard: FIX IN HAND, need r=,sr=
Well, I could have sworn this worked on Windows in initial testing, but now I'm finding that the filepicker's "displayDirectory" returned is always my VC++ project directory, not the one I used to select a file. Weird.
moving milestone. Note that the existing fix checked in no longer works because of a new bug in FilePicker (bug to be filed soon).
Target Milestone: mozilla0.9.8 → mozilla0.9.9
This uses the filePicker.file.parent to get the directory of the file picked by user, which gets around current problems in filepicker (displayDirectory is *not* the last user location; Bill Law is fixing this in Windows but it's not clear if displayDirectory should do that anyway!)
Attachment #64094 - Attachment is obsolete: true
Comment on attachment 66220 [details] [diff] [review] Updated fix to use nsILocalFile for prefs r=law
Attachment #66220 - Flags: review+
Whiteboard: FIX IN HAND, need r=,sr= → FIX IN HAND, need sr=
Comment on attachment 66220 [details] [diff] [review] Updated fix to use nsILocalFile for prefs sr=dveditz
Attachment #66220 - Flags: superreview+
checked in.
Status: ASSIGNED → RESOLVED
Closed: 23 years ago23 years ago
Keywords: patch, review
Resolution: --- → FIXED
Whiteboard: FIX IN HAND, need sr=
Verified on Win 2k using the 01-27 trunk build, and Mac OSX using the 01-28 trunk build.
Status: RESOLVED → VERIFIED
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: