Bug 41964

Summary: [chromium] popup menu should have the capability of showing labels
Product: WebKit Reporter: Jay Civelli <jcivelli>
Component: WebKit Misc.Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth, commit-queue, dglazkov, eric, fishd, jhawkins, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   
Attachments:
Description Flags
Initial patch
none
Fixed style issues
tkent: review-
Fixing Mac build
tkent: review-
Changed AutoFillPopupMenuClient::convertListIndexToInternalIndex to return a signed int none

Description Jay Civelli 2010-07-09 10:19:04 PDT
For the Chromium autofill related feature, we need the PopupMenuChromium to be able to display a custom label on the right side for each entry.
Comment 1 Jay Civelli 2010-07-09 10:47:54 PDT
Created attachment 61060 [details]
Initial patch
Comment 2 WebKit Review Bot 2010-07-09 16:48:11 PDT
Attachment 61060 [details] did not pass style-queue:

Failed to run "['WebKitTools/Scripts/check-webkit-style']" exit_code: 1
WebKit/chromium/src/AutoFillPopupMenuClient.cpp:280:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
WebCore/platform/chromium/PopupMenuChromium.cpp:915:  One line control clauses should not use braces.  [whitespace/braces] [4]
WebCore/platform/chromium/PopupMenuChromium.cpp:961:  One line control clauses should not use braces.  [whitespace/braces] [4]
Total errors found: 3 in 10 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Eric Seidel (no email) 2010-07-09 16:55:59 PDT
Attachment 61060 [details] did not build on mac:
Build output: http://webkit-commit-queue.appspot.com/results/3507040
Comment 4 Jay Civelli 2010-07-09 16:58:49 PDT
Created attachment 61115 [details]
Fixed style issues
Comment 5 Eric Seidel (no email) 2010-07-09 17:09:02 PDT
Attachment 61115 [details] did not build on mac:
Build output: http://webkit-commit-queue.appspot.com/results/3488087
Comment 6 Kent Tamura 2010-07-12 03:02:12 PDT
Comment on attachment 61115 [details]
Fixed style issues

The code looks OK.  Please fix the build error:

/Users/eseidel/Projects/MacEWS/WebKitBuild/WebCore.build/Release/WebCore.build/Objects-normal/i386/RenderTextControlSingleLine.o
cc1plus: warnings being treated as errors
/Users/eseidel/Projects/MacEWS/WebCore/rendering/RenderTextControlSingleLine.cpp:879: warning: unused parameter 'listIndex'
distcc[99406] ERROR: compile /Users/eseidel/Projects/MacEWS/WebCore/rendering/RenderTextControlSingleLine.cpp on localhost failed


WebCore/platform/chromium/PopupMenuChromium.cpp:73
 +  static const int kTextToLabelPadding = 10;
nit: We don't prepend 'k' prefix to constant value symbols.  This change is ok for consistency.
Comment 7 Jay Civelli 2010-07-12 10:58:54 PDT
Created attachment 61245 [details]
Fixing Mac build
Comment 8 Kent Tamura 2010-07-12 16:27:09 PDT
Comment on attachment 61245 [details]
Fixing Mac build

WebKit/chromium/src/AutoFillPopupMenuClient.cpp:70
 +      if (index == -1)
I don't think this code works.  A compiler warns "signed vs. unsigned" and removes the code by optimization.
convertListIndexToInternalIndex() should return signed int.
Comment 9 Jay Civelli 2010-07-12 17:16:54 PDT
Created attachment 61298 [details]
Changed  AutoFillPopupMenuClient::convertListIndexToInternalIndex to return a signed int
Comment 10 Kent Tamura 2010-07-12 18:28:02 PDT
Comment on attachment 61298 [details]
Changed  AutoFillPopupMenuClient::convertListIndexToInternalIndex to return a signed int

OK.
Comment 11 WebKit Commit Bot 2010-07-12 23:41:25 PDT
Comment on attachment 61298 [details]
Changed  AutoFillPopupMenuClient::convertListIndexToInternalIndex to return a signed int

Clearing flags on attachment: 61298

Committed r63179: <http://trac.webkit.org/changeset/63179>
Comment 12 WebKit Commit Bot 2010-07-12 23:41:30 PDT
All reviewed patches have been landed.  Closing bug.