From 9b8b4d375a9ce7cc52b6d42046a4947f58b8648d Mon Sep 17 00:00:00 2001 From: "danno@chromium.org" Date: Thu, 25 Mar 2010 11:00:04 +0000 Subject: [Mac] Make cookie prompt dialog more Mac-like As per Alcor's recommendations, customize the Mac cookie prompt so that it is a less like windows/linux but more "maccy": add application icon for modal dialog, change layout and make radio buttons in "remember" choice small rather than regular. Also added unit tests. xib changes: - Add application icon to cookie prompt dialog, shifting all other elements to the right accordingly. - Change the size of the radio buttons in the "remember" choice to be small rather than regular. - Change the default text in in the information NSTextField to "Label" rather than a really long nonsensical debug string - Move the details view to be below the accept/block buttons. - Change the style of the disclosure control to be a button rather than triangle. Before: http://img257.yfrog.com/img257/3066/picture3fx.png After: http://img214.imageshack.us/img214/5553/picture9es.png and http://img200.imageshack.us/img200/1558/picture10pm.png BUG=38208 TEST=manual testing, added unit test for remember/block/accept controls Review URL: http://codereview.chromium.org/1102005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42597 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/app/nibs/CookiePrompt.xib | 384 ++++++++++++++++++++++----------------- 1 file changed, 219 insertions(+), 165 deletions(-) (limited to 'chrome/app') diff --git a/chrome/app/nibs/CookiePrompt.xib b/chrome/app/nibs/CookiePrompt.xib index 2d4c4e3..233d8f2 100644 --- a/chrome/app/nibs/CookiePrompt.xib +++ b/chrome/app/nibs/CookiePrompt.xib @@ -2,13 +2,13 @@ 1050 - 9L30 + 9L31a 680 949.54 353.00 YES - + YES @@ -37,7 +37,7 @@ 1 2 - {{450, 361}, {504, 361}} + {{450, 290}, {591, 332}} 611844096 NSWindow @@ -48,71 +48,16 @@ 274 YES - - - 289 - - YES - - - 268 - {{104, -6}, {125, 32}} - - YES - - 67239424 - 134217728 - ^IDS_COOKIE_ALERT_BLOCK_BUTTON - - LucidaGrande - 1.300000e+01 - 1044 - - - -2038284033 - 129 - - - 200 - 25 - - - - - 268 - {{229, -6}, {125, 32}} - - YES - - 67239424 - 134217728 - ^IDS_COOKIE_ALERT_ALLOW_BUTTON - - - -2038284033 - 129 - - DQ - 200 - 25 - - - - {{136, 20}, {348, 22}} - - GTMWidthBasedTweaker - 268 - {{17, 324}, {470, 17}} + {{104, 295}, {470, 17}} YES -2080244224 272629760 - TWVzc2FnZSB0aGF0IGlzIHJlYWxseSBsb25nIGFuZCBhY3R1YWxseSBuZWVkcyB0byBiZSB3cmFwcGVk -IGV2ZW4gdGhvdWdoIGluIHRoZSBub3JtYWwgY2FzZSBpdCBpc24ndA + Label LucidaGrande-Bold 1.300000e+01 @@ -142,7 +87,7 @@ IGV2ZW4gdGhvdWdoIGluIHRoZSBub3JtYWwgY2FzZSBpdCBpc24ndA 268 - {{20, 282}, {464, 34}} + {{107, 249}, {464, 38}} YES 2 @@ -151,9 +96,13 @@ IGV2ZW4gdGhvdWdoIGluIHRoZSBub3JtYWwgY2FzZSBpdCBpc24ndA YES -2080244224 - 0 + 131072 ^IDS_COOKIE_ALERT_REMEMBER_RADIO - + + LucidaGrande + 1.100000e+01 + 3100 + 1 1211912703 @@ -168,9 +117,9 @@ IGV2ZW4gdGhvdWdoIGluIHRoZSBub3JtYWwgY2FzZSBpdCBpc24ndA 67239424 - 0 + 131072 ^IDS_COOKIE_ALERT_ASK_RADIO - + 1211912703 128 @@ -275,15 +224,19 @@ QXBwbGUgQ29tcHV0ZXIsIEluYy4sIDIwMDUAAAAAA 75 - {464, 16} + {464, 18} {4, 2} 1151868928 NSActionCell 67239424 - 0 + 262144 Radio - + + LucidaGrande + 9.000000e+00 + 3614 + 1211912703 0 @@ -342,55 +295,98 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA - + + LucidaGrande + 1.300000e+01 + 1044 + 266 YES - + 268 - {{0, 196}, {13, 13}} + {{-4, 197}, {29, 26}} YES - + 67239424 - 67108864 + 134217728 - - -1195622145 - 133 + + 918831359 + 166 - 200 - 25 + 400 + 75 - + - 266 - {464, 191} + 289 + + YES + + + 268 + {{104, -6}, {125, 32}} + + YES + + 67239424 + 134217728 + ^IDS_COOKIE_ALERT_BLOCK_BUTTON + + + -2038284033 + 129 + + + 200 + 25 + + + + + 268 + {{229, -6}, {125, 32}} + + YES + + 67239424 + 134217728 + ^IDS_COOKIE_ALERT_ALLOW_BUTTON + + + -2038284033 + 129 + + DQ + 200 + 25 + + + + {{116, 199}, {348, 22}} - NSView + GTMWidthBasedTweaker 268 - {{17, 195}, {199, 14}} + {{26, 203}, {199, 14}} YES 68288064 272761856 ^IDS_COOKIE_SHOW_DETAILS_LABEL - - LucidaGrande - 1.100000e+01 - 3100 - + @@ -401,13 +397,52 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA + + + 266 + {464, 191} + + NSView + - {{20, 60}, {464, 214}} + {{107, 20}, {464, 221}} NSView + + + 268 + + YES + + YES + Apple PDF pasteboard type + Apple PICT pasteboard type + Apple PNG pasteboard type + NSFilenamesPboardType + NeXT Encapsulated PostScript v1.2 pasteboard type + NeXT TIFF v4.0 pasteboard type + + + {{20, 248}, {64, 64}} + + YES + + 130560 + 33554432 + + NSImage + app + + 0 + 0 + 0 + NO + + YES + - {504, 361} + {591, 332} {{0, 0}, {1440, 878}} @@ -424,22 +459,6 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA YES - - disclosureTrianglePressed: - - - - 76 - - - - disclosureTriangle_ - - - - 77 - - rememberChoiceCell_ @@ -497,14 +516,6 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA - disclosureTriangleSuperView_ - - - - 146 - - - radioGroupMatrix_ @@ -527,13 +538,37 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA 151 + + + disclosureButton_ + + + + 158 + + + + disclosureButtonPressed: + + + + 159 + + + + disclosureButtonSuperView_ + + + + 160 + YES 0 - + YES @@ -542,19 +577,19 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA -2 - + RmlsZSdzIE93bmVyA -1 - + First Responder -3 - + Application @@ -564,24 +599,24 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA YES - + 89 YES + - 96 - + 106 @@ -589,26 +624,13 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA YES - + + - 73 - - - YES - - - - - - 74 - - - - 117 @@ -616,21 +638,7 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA 128 - - - - 136 - - - YES - - - - - - 137 - - + 112 @@ -673,6 +681,34 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA + 154 + + + YES + + + + + + 155 + + + + + 136 + + + YES + + + + + + 137 + + + + 94 @@ -680,7 +716,7 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA - + 90 @@ -692,11 +728,6 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA - 91 - - - - 92 @@ -710,6 +741,25 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA + + 91 + + + + + 156 + + + YES + + + + + + 157 + + + @@ -726,12 +776,14 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA 128.IBPluginDependency 136.IBPluginDependency 137.IBPluginDependency + 154.IBPluginDependency + 155.IBPluginDependency + 156.IBPluginDependency + 157.IBPluginDependency 69.IBPluginDependency 70.IBPluginDependency 71.IBPluginDependency 72.IBPluginDependency - 73.IBPluginDependency - 74.IBPluginDependency 88.IBEditorWindowLastContentRect 88.IBPluginDependency 88.IBWindowTemplateEditedContentRect @@ -762,9 +814,11 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin - {{72, 330}, {504, 361}} com.apple.InterfaceBuilder.CocoaPlugin - {{72, 330}, {504, 361}} + com.apple.InterfaceBuilder.CocoaPlugin + {{131, 330}, {591, 332}} + com.apple.InterfaceBuilder.CocoaPlugin + {{131, 330}, {591, 332}} com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin @@ -795,7 +849,7 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA - 153 + 160 @@ -817,7 +871,7 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA YES accept: block: - disclosureTrianglePressed: + disclosureButtonPressed: YES @@ -832,8 +886,8 @@ AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA YES description_ disclosedViewPlaceholder_ - disclosureTriangleSuperView_ - disclosureTriangle_ + disclosureButtonSuperView_ + disclosureButton_ radioGroupMatrix_ rememberChoiceCell_ -- cgit v1.1