Closed
Bug 404279
Opened 17 years ago
Closed 16 years ago
Suggest automatic filling of 'name' field after selecting "add a keyword for this search" from context menu.
Categories
(Firefox :: Bookmarks & History, enhancement)
Firefox
Bookmarks & History
Tracking
()
VERIFIED
FIXED
Firefox 3.6a1
People
(Reporter: sean.van.der.smythe, Assigned: mkohler)
Details
Attachments
(1 file, 5 obsolete files)
2.64 KB,
patch
|
mkohler
:
review+
mkohler
:
ui-review+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6
I suggest automatic filling on the 'name' field after selecting "add a keyword for this search" from context menu. The name could be automatically filled in based on the name of the page (the one that appears in the title bar).
Reproducible: Always
Steps to Reproduce:
1. Right click in a website text box designed for sending queries.
2. Select "add a keyword for this search".
3. Notice that the 'name' field is blank.
4. Wish that it was already filled in, based on the name of the webpage in question.
Actual Results:
'Name' field was blank. I had to fill it in.
Expected Results:
The 'name' field should have contained the name of the page in which the search box was encountered.
Updated•17 years ago
|
Component: Search → Places
OS: Windows XP → All
QA Contact: search → places
Hardware: PC → All
Version: unspecified → Trunk
Comment 2•17 years ago
|
||
I'm thinking many pages a user creates a search keyword bookmark for is probably also in their bookmark collection. For example bugzilla.mozilla.org and search for a bug #. having them both automatically named the same thing is confusing. I'd prefer to name the search something unique to distinguish it from the page bookmark.
Perhaps the auto fill of "add a keyword for this search..." Name: field could be something like <page name> - keyword or <page name> search ?
Comment 3•17 years ago
|
||
(In reply to comment #2)
> Perhaps the auto fill of "add a keyword for this search..." Name: field could
> be something like <page name> - keyword or <page name> search ?
For long page titles the additional keyword or search part will not be seen while it's too much on the right side and users normally don't have such a wide sidebar or Library window. Perhaps placing "Search: " in front of the page title would be a nice option.
Assignee | ||
Updated•16 years ago
|
Assignee: nobody → michaelkohler
Status: NEW → ASSIGNED
Target Milestone: --- → Firefox 3.6a1
Assignee | ||
Comment 4•16 years ago
|
||
This puts "Keyword:" in front of it. Like that we don't have to localize I guess..
Attachment #374700 -
Flags: review?(mak77)
Assignee | ||
Updated•16 years ago
|
Whiteboard: [needs review mak77]
Updated•16 years ago
|
Attachment #374700 -
Flags: review?(mak77) → review-
Comment 5•16 years ago
|
||
Comment on attachment 374700 [details] [diff] [review]
Patch v1
We do in fact have to localize this because of RTL languages.
Assignee | ||
Updated•16 years ago
|
Whiteboard: [needs review mak77]
Assignee | ||
Comment 6•16 years ago
|
||
Attachment #374700 -
Attachment is obsolete: true
Attachment #374704 -
Flags: review?(sdwilsh)
Assignee | ||
Comment 7•16 years ago
|
||
Now also with the correct variable name (prefix instead of sitename).. Sorry about that.
Attachment #374704 -
Attachment is obsolete: true
Attachment #374706 -
Flags: review?(sdwilsh)
Attachment #374704 -
Flags: review?(sdwilsh)
Comment 8•16 years ago
|
||
Comment on attachment 374706 [details] [diff] [review]
Patch v1.2 (localizable + correct variable name)
My point was that you can't assume that we always want to prefix it as it is going to be locale independent. mak is also the appropriate reviewer when this patch is ready.
Attachment #374706 -
Flags: review?(sdwilsh) → review-
Assignee | ||
Comment 9•16 years ago
|
||
Attachment #374706 -
Attachment is obsolete: true
Attachment #374795 -
Flags: review?(mak77)
Assignee | ||
Updated•16 years ago
|
Whiteboard: [needs review mak77]
Comment 10•16 years ago
|
||
Comment on attachment 374795 [details] [diff] [review]
Patch v2 (fully localizable I hope)
>diff --git a/browser/base/content/browser.js b/browser/base/content/browser.js
>--- a/browser/base/content/browser.js
>+++ b/browser/base/content/browser.js
>@@ -5796,18 +5796,20 @@ function AddKeywordForSearchField()
>
> var postData;
>
> if (isURLEncoded)
> postData = formData.join("&");
> else
> spec += "?" + formData.join("&");
>
>+ var title = gNavigatorBundle.getFormattedString("searchKeyword.autofilling",
>+ new Array(node.ownerDocument.title));
instead of new Array simply use [node.ownerDocument.title]
also please move this in the upper part of the method where we gather other informations, should be cleaner.
>diff --git a/browser/locales/en-US/chrome/browser/browser.properties b/browser/locales/en-US/chrome/browser/browser.properties
>--- a/browser/locales/en-US/chrome/browser/browser.properties
>+++ b/browser/locales/en-US/chrome/browser/browser.properties
>@@ -199,8 +199,12 @@ safebrowsing.notAnAttackButton.accessKey
> # LOCALIZATION NOTE (privateBrowsingYesTitle, privateBrowsingNoTitle, privateBrowsingNeverAsk):
> # Access keys are specified by prefixing the desired letter with an ampersand.
> privateBrowsingDialogTitle=Start Private Browsing
> privateBrowsingMessageHeader=Would you like to start Private Browsing?
> privateBrowsingMessage=%S will save your current tabs for when you are done with your Private Browsing session.
> privateBrowsingYesTitle=&Start Private Browsing
> privateBrowsingNoTitle=&Cancel
> privateBrowsingNeverAsk=&Do not show this message again
>+
>+# Used as prefix/postfix for the autofilled keyword name when saving a search keyword
>+# LOCALIZATION NOTE (keywordSearch.autofilling): %S will be replaced by the site's title
>+searchKeyword.autofilling=Keyword: %S
call this addKeywordTitleAutoFill, i prefer the "Search: " prefix, should help non-techical users, but we can ask an ui-r on that later.
LOCALIZATION NODE should point to the same name as the property, and any eventual comment should be after it, not before.
Please on next patch ask an ui-r to faaborg or boriss for the choice of the prefix.
Attachment #374795 -
Flags: review?(mak77) → review-
Assignee | ||
Comment 11•16 years ago
|
||
this includes the changes from comment 10.
Attachment #374795 -
Attachment is obsolete: true
Attachment #376042 -
Flags: ui-review?
Attachment #376042 -
Flags: review?(mak77)
Assignee | ||
Updated•16 years ago
|
Attachment #376042 -
Flags: ui-review? → ui-review?(faaborg)
Comment 12•16 years ago
|
||
Comment on attachment 376042 [details] [diff] [review]
includes the changes from comment 10
>diff --git a/browser/locales/en-US/chrome/browser/browser.properties b/browser/locales/en-US/chrome/browser/browser.properties
>--- a/browser/locales/en-US/chrome/browser/browser.properties
>+++ b/browser/locales/en-US/chrome/browser/browser.properties
>@@ -199,8 +199,12 @@ safebrowsing.notAnAttackButton.accessKey
> # LOCALIZATION NOTE (privateBrowsingYesTitle, privateBrowsingNoTitle, privateBrowsingNeverAsk):
> # Access keys are specified by prefixing the desired letter with an ampersand.
> privateBrowsingDialogTitle=Start Private Browsing
> privateBrowsingMessageHeader=Would you like to start Private Browsing?
> privateBrowsingMessage=%S will save your current tabs for when you are done with your Private Browsing session.
> privateBrowsingYesTitle=&Start Private Browsing
> privateBrowsingNoTitle=&Cancel
> privateBrowsingNeverAsk=&Do not show this message again
>+
>+# LOCALIZATION NOTE (addKeywordTitleAutoFill): %S will be replaced by the site's title
"by the page's title"
>+# Used as prefix/postfix for the autofilled keyword name when saving a search keyword
i would remove "as a prefix/postfix" since this also includes title, so maybe "Used as the bookmark name when saving a keyword for a search field."
r=me with those fixed, waiting for ui-r for the prefix choice, but i personally like "Search: page title"
Attachment #376042 -
Flags: review?(mak77) → review+
Updated•16 years ago
|
Whiteboard: [needs review mak77]
Assignee | ||
Updated•16 years ago
|
Attachment #376042 -
Flags: ui-review?(faaborg) → ui-review?(limi)
Updated•16 years ago
|
Attachment #376042 -
Flags: ui-review?(limi) → ui-review+
Comment 13•16 years ago
|
||
Comment on attachment 376042 [details] [diff] [review]
includes the changes from comment 10
After a bunch of debating on Keyword Search vs. Search, I think Search is probably fine. We should lose the : though, just:
Search CNN.com - Breaking News
or
Search Bugzilla@Mozilla
Assignee | ||
Comment 14•16 years ago
|
||
mak's and beltzner's changes included.
Attachment #376042 -
Attachment is obsolete: true
Attachment #376305 -
Flags: ui-review+
Attachment #376305 -
Flags: review+
Assignee | ||
Updated•16 years ago
|
Keywords: checkin-needed
Comment 15•16 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/9eace9771241
This can't make 1.9.1 due to l10n changes.
Comment 16•16 years ago
|
||
Verified fixed on trunk with builds on Windows and OS X:
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.2a1pre) Gecko/20090513 Minefield/3.6a1pre ID:20090513034237
Status: RESOLVED → VERIFIED
Component: Places → Bookmarks & History
QA Contact: places → bookmarks
Comment 17•16 years ago
|
||
Could anyone give a screenshot with this feature in use?
I don't quite understand how to localize it yet...
Comment 18•16 years ago
|
||
(In reply to comment #17)
> Could anyone give a screenshot with this feature in use?
>
> I don't quite understand how to localize it yet...
The proposal is just the web page title with "Search " as prefix, e.g. "yahoo Deutschland" => "Search yahoo Deutschland".
You need to log in
before you can comment on or make changes to this bug.
Description
•