diff options
author | mirandac@chromium.org <mirandac@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-11-03 16:15:32 +0000 |
---|---|---|
committer | mirandac@chromium.org <mirandac@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-11-03 16:15:32 +0000 |
commit | 3896b185aa328b422ebfd002e382e0186ec3fbd7 (patch) | |
tree | d2a6db357bf72adeaff75b4953ad560e96215913 | |
parent | 71aa3446235a444e69185f972b5cec8216f64374 (diff) | |
download | chromium_src-3896b185aa328b422ebfd002e382e0186ec3fbd7.zip chromium_src-3896b185aa328b422ebfd002e382e0186ec3fbd7.tar.gz chromium_src-3896b185aa328b422ebfd002e382e0186ec3fbd7.tar.bz2 |
Add "Report Bug" dialog to Mac OSX.
BUG= http://crbug.com/19282
TEST= Use report bug dialog on Mac OSX.
Review URL: http://codereview.chromium.org/340039
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30815 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/app/nibs/MainMenu.xib | 33 | ||||
-rw-r--r-- | chrome/app/nibs/ReportBug.xib | 1103 | ||||
-rw-r--r-- | chrome/browser/app_controller_mac.mm | 13 | ||||
-rw-r--r-- | chrome/browser/cocoa/browser_window_cocoa.mm | 10 | ||||
-rw-r--r-- | chrome/browser/cocoa/bug_report_window_controller.h | 88 | ||||
-rw-r--r-- | chrome/browser/cocoa/bug_report_window_controller.mm | 157 | ||||
-rw-r--r-- | chrome/browser/cocoa/bug_report_window_controller_unittest.mm | 71 | ||||
-rwxr-xr-x | chrome/chrome.gyp | 5 |
8 files changed, 1467 insertions, 13 deletions
diff --git a/chrome/app/nibs/MainMenu.xib b/chrome/app/nibs/MainMenu.xib index a2863af..f4f713c 100644 --- a/chrome/app/nibs/MainMenu.xib +++ b/chrome/app/nibs/MainMenu.xib @@ -8,6 +8,7 @@ <string key="IBDocument.HIToolboxVersion">353.00</string> <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="106"/> </object> <object class="NSArray" key="IBDocument.PluginDependencies"> <bool key="EncodedWithXMLCoder">YES</bool> @@ -1045,6 +1046,7 @@ <int key="NSMnemonicLoc">2147483647</int> <reference key="NSOnImage" ref="353210768"/> <reference key="NSMixedImage" ref="549394948"/> + <int key="NSTag">40008</int> </object> <object class="NSMenuItem" id="679532991"> <reference key="NSMenu" ref="374024848"/> @@ -1548,25 +1550,25 @@ <object class="IBActionConnection" key="connection"> <string key="label">commandDispatch:</string> <reference key="source" ref="1014"/> - <reference key="destination" ref="238773614"/> + <reference key="destination" ref="679532991"/> </object> - <int key="connectionID">650</int> + <int key="connectionID">651</int> </object> <object class="IBConnectionRecord"> <object class="IBActionConnection" key="connection"> <string key="label">commandDispatch:</string> <reference key="source" ref="1014"/> - <reference key="destination" ref="679532991"/> + <reference key="destination" ref="774017921"/> </object> - <int key="connectionID">651</int> + <int key="connectionID">653</int> </object> <object class="IBConnectionRecord"> <object class="IBActionConnection" key="connection"> <string key="label">commandDispatch:</string> <reference key="source" ref="1014"/> - <reference key="destination" ref="774017921"/> + <reference key="destination" ref="238773614"/> </object> - <int key="connectionID">653</int> + <int key="connectionID">655</int> </object> </object> <object class="IBMutableOrderedSet" key="objectRecords"> @@ -2579,7 +2581,7 @@ <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <integer value="1" id="9"/> - <string>{{1391, 294}, {335, 43}}</string> + <string>{{1304, 280}, {335, 43}}</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> <string>{{596, 852}, {216, 23}}</string> @@ -2587,7 +2589,7 @@ <reference ref="9"/> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> - <string>{{607, 668}, {64, 6}}</string> + <string>{{519, 240}, {64, 6}}</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> <string>{{436, 809}, {64, 6}}</string> @@ -2671,7 +2673,7 @@ <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> <string>{{525, 802}, {197, 73}}</string> - <string>{{3, 337}, {1578, 20}}</string> + <string>{{-87, 323}, {1578, 20}}</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> <string>{74, 862}</string> @@ -2736,7 +2738,7 @@ <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> - <string>{{12, 124}, {385, 213}}</string> + <string>{{80, 101}, {385, 213}}</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> <string>{{23, 794}, {245, 183}}</string> @@ -2766,7 +2768,7 @@ <reference ref="9"/> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> - <string>{{106, 34}, {350, 303}}</string> + <string>{{160, 20}, {353, 303}}</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <reference ref="9"/> <string>{{323, 672}, {199, 203}}</string> @@ -2798,7 +2800,7 @@ </object> </object> <nil key="sourceID"/> - <int key="maxID">653</int> + <int key="maxID">655</int> </object> <object class="IBClassDescriber" key="IBDocument.Classes"> <object class="NSMutableArray" key="referencedPartialClassDescriptions"> @@ -2963,6 +2965,13 @@ </object> </object> <object class="IBPartialClassDescription"> + <string key="className">NSMenuItem</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">browser/cocoa/nsmenuitem_additions.h</string> + </object> + </object> + <object class="IBPartialClassDescription"> <string key="className">NSObject</string> <object class="IBClassDescriptionSource" key="sourceIdentifier"> <string key="majorKey">IBProjectSource</string> diff --git a/chrome/app/nibs/ReportBug.xib b/chrome/app/nibs/ReportBug.xib new file mode 100644 index 0000000..267e4a2 --- /dev/null +++ b/chrome/app/nibs/ReportBug.xib @@ -0,0 +1,1103 @@ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.03"> + <data> + <int key="IBDocument.SystemTarget">1050</int> + <string key="IBDocument.SystemVersion">9L31a</string> + <string key="IBDocument.InterfaceBuilderVersion">677</string> + <string key="IBDocument.AppKitVersion">949.54</string> + <string key="IBDocument.HIToolboxVersion">353.00</string> + <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="108"/> + </object> + <object class="NSArray" key="IBDocument.PluginDependencies"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + </object> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSCustomObject" id="1001"> + <string key="NSClassName">BugReportWindowController</string> + </object> + <object class="NSCustomObject" id="1003"> + <string key="NSClassName">FirstResponder</string> + </object> + <object class="NSCustomObject" id="1004"> + <string key="NSClassName">NSApplication</string> + </object> + <object class="NSWindowTemplate" id="1005"> + <int key="NSWindowStyleMask">1</int> + <int key="NSWindowBacking">2</int> + <string key="NSWindowRect">{{196, 220}, {500, 290}}</string> + <int key="NSWTFlags">536870912</int> + <string key="NSWindowTitle">^IDS_BUGREPORT_TITLE</string> + <string key="NSWindowClass">NSWindow</string> + <nil key="NSViewClass"/> + <string key="NSWindowContentMaxSize">{3.40282e+38, 3.40282e+38}</string> + <object class="NSView" key="NSWindowView" id="1006"> + <reference key="NSNextResponder"/> + <int key="NSvFlags">256</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSCustomView" id="97454414"> + <reference key="NSNextResponder" ref="1006"/> + <int key="NSvFlags">289</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSButton" id="89080441"> + <reference key="NSNextResponder" ref="97454414"/> + <int key="NSvFlags">301</int> + <string key="NSFrame">{{349, 12}, {96, 32}}</string> + <reference key="NSSuperview" ref="97454414"/> + <bool key="NSEnabled">YES</bool> + <object class="NSButtonCell" key="NSCell" id="100321947"> + <int key="NSCellFlags">67239424</int> + <int key="NSCellFlags2">134217728</int> + <string key="NSContents">^IDS_CANCEL</string> + <object class="NSFont" key="NSSupport" id="702304060"> + <string key="NSName">LucidaGrande</string> + <double key="NSSize">1.300000e+01</double> + <int key="NSfFlags">1044</int> + </object> + <reference key="NSControlView" ref="89080441"/> + <int key="NSButtonFlags">-2038284033</int> + <int key="NSButtonFlags2">129</int> + <string key="NSAlternateContents"/> + <string key="NSKeyEquivalent"/> + <int key="NSPeriodicDelay">200</int> + <int key="NSPeriodicInterval">25</int> + </object> + </object> + <object class="NSButton" id="833160383"> + <reference key="NSNextResponder" ref="97454414"/> + <int key="NSvFlags">297</int> + <string key="NSFrame">{{253, 12}, {96, 32}}</string> + <reference key="NSSuperview" ref="97454414"/> + <bool key="NSEnabled">YES</bool> + <object class="NSButtonCell" key="NSCell" id="629834119"> + <int key="NSCellFlags">67239424</int> + <int key="NSCellFlags2">134217728</int> + <string key="NSContents">^IDS_BUGREPORT_SEND_REPORT</string> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="833160383"/> + <int key="NSButtonFlags">-2038284033</int> + <int key="NSButtonFlags2">129</int> + <string key="NSAlternateContents"/> + <string key="NSKeyEquivalent"/> + <int key="NSPeriodicDelay">200</int> + <int key="NSPeriodicInterval">25</int> + </object> + </object> + </object> + <string key="NSFrame">{{41, 0}, {459, 60}}</string> + <reference key="NSSuperview" ref="1006"/> + <string key="NSClassName">GTMWidthBasedTweaker</string> + </object> + <object class="NSCustomView" id="1006320362"> + <reference key="NSNextResponder" ref="1006"/> + <int key="NSvFlags">268</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSTextField" id="824407095"> + <reference key="NSNextResponder" ref="1006320362"/> + <int key="NSvFlags">265</int> + <string key="NSFrame">{{17, 156}, {87, 17}}</string> + <reference key="NSSuperview" ref="1006320362"/> + <bool key="NSEnabled">YES</bool> + <object class="NSTextFieldCell" key="NSCell" id="157068629"> + <int key="NSCellFlags">68288064</int> + <int key="NSCellFlags2">71304192</int> + <string key="NSContents">^IDS_BUGREPORT_REPORT_PAGE_TITLE</string> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="824407095"/> + <object class="NSColor" key="NSBackgroundColor" id="174239665"> + <int key="NSColorSpace">6</int> + <string key="NSCatalogName">System</string> + <string key="NSColorName">controlColor</string> + <object class="NSColor" key="NSColor"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MC42NjY2NjY2OQA</bytes> + </object> + </object> + <object class="NSColor" key="NSTextColor" id="281508086"> + <int key="NSColorSpace">6</int> + <string key="NSCatalogName">System</string> + <string key="NSColorName">controlTextColor</string> + <object class="NSColor" key="NSColor" id="1037439676"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MAA</bytes> + </object> + </object> + </object> + </object> + <object class="NSTextField" id="319457361"> + <reference key="NSNextResponder" ref="1006320362"/> + <int key="NSvFlags">265</int> + <string key="NSFrame">{{17, 185}, {87, 17}}</string> + <reference key="NSSuperview" ref="1006320362"/> + <bool key="NSEnabled">YES</bool> + <object class="NSTextFieldCell" key="NSCell" id="89599916"> + <int key="NSCellFlags">68288064</int> + <int key="NSCellFlags2">71304192</int> + <string key="NSContents">^IDS_BUGREPORT_BUG_TYPE</string> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="319457361"/> + <reference key="NSBackgroundColor" ref="174239665"/> + <reference key="NSTextColor" ref="281508086"/> + </object> + </object> + <object class="NSTextField" id="785984542"> + <reference key="NSNextResponder" ref="1006320362"/> + <int key="NSvFlags">265</int> + <string key="NSFrame">{{17, 129}, {87, 17}}</string> + <reference key="NSSuperview" ref="1006320362"/> + <bool key="NSEnabled">YES</bool> + <object class="NSTextFieldCell" key="NSCell" id="677642034"> + <int key="NSCellFlags">68288064</int> + <int key="NSCellFlags2">71304192</int> + <string key="NSContents">^IDS_BUGREPORT_REPORT_URL_LABEL</string> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="785984542"/> + <reference key="NSBackgroundColor" ref="174239665"/> + <reference key="NSTextColor" ref="281508086"/> + </object> + </object> + <object class="NSTextField" id="172513261"> + <reference key="NSNextResponder" ref="1006320362"/> + <int key="NSvFlags">265</int> + <string key="NSFrame">{{17, 101}, {87, 17}}</string> + <reference key="NSSuperview" ref="1006320362"/> + <bool key="NSEnabled">YES</bool> + <object class="NSTextFieldCell" key="NSCell" id="610895328"> + <int key="NSCellFlags">68288064</int> + <int key="NSCellFlags2">71304192</int> + <string key="NSContents">^IDS_BUGREPORT_DESCRIPTION_LABEL</string> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="172513261"/> + <reference key="NSBackgroundColor" ref="174239665"/> + <reference key="NSTextColor" ref="281508086"/> + </object> + </object> + </object> + <string key="NSFrame">{{0, 68}, {101, 222}}</string> + <reference key="NSSuperview" ref="1006"/> + <string key="NSClassName">GTMWidthBasedTweaker</string> + </object> + <object class="NSBox" id="577841338"> + <reference key="NSNextResponder" ref="1006"/> + <int key="NSvFlags">36</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSView" id="647799232"> + <reference key="NSNextResponder" ref="577841338"/> + <int key="NSvFlags">256</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSTextField" id="686336864"> + <reference key="NSNextResponder" ref="647799232"/> + <int key="NSvFlags">266</int> + <string key="NSFrame">{{-1, 174}, {377, 17}}</string> + <reference key="NSSuperview" ref="647799232"/> + <bool key="NSEnabled">YES</bool> + <object class="NSTextFieldCell" key="NSCell" id="190256621"> + <int key="NSCellFlags">68288064</int> + <int key="NSCellFlags2">272630784</int> + <string key="NSContents">page</string> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="686336864"/> + <reference key="NSBackgroundColor" ref="174239665"/> + <reference key="NSTextColor" ref="281508086"/> + </object> + </object> + <object class="NSPopUpButton" id="304367917"> + <reference key="NSNextResponder" ref="647799232"/> + <int key="NSvFlags">266</int> + <string key="NSFrame">{{-1, 195}, {377, 26}}</string> + <reference key="NSSuperview" ref="647799232"/> + <bool key="NSEnabled">YES</bool> + <object class="NSPopUpButtonCell" key="NSCell" id="405291569"> + <int key="NSCellFlags">-2076049856</int> + <int key="NSCellFlags2">2048</int> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="304367917"/> + <int key="NSButtonFlags">109199615</int> + <int key="NSButtonFlags2">129</int> + <string key="NSAlternateContents"/> + <string key="NSKeyEquivalent"/> + <int key="NSPeriodicDelay">400</int> + <int key="NSPeriodicInterval">75</int> + <nil key="NSMenuItem"/> + <bool key="NSMenuItemRespectAlignment">YES</bool> + <object class="NSMenu" key="NSMenu" id="1060400312"> + <string key="NSTitle">OtherViews</string> + <object class="NSMutableArray" key="NSMenuItems"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <int key="NSSelectedIndex">-1</int> + <int key="NSPreferredEdge">1</int> + <bool key="NSUsesItemFromMenu">YES</bool> + <bool key="NSAltersState">YES</bool> + <int key="NSArrowPosition">2</int> + </object> + </object> + <object class="NSTextField" id="925947608"> + <reference key="NSNextResponder" ref="647799232"/> + <int key="NSvFlags">266</int> + <string key="NSFrame">{{2, 144}, {371, 22}}</string> + <reference key="NSSuperview" ref="647799232"/> + <bool key="NSEnabled">YES</bool> + <object class="NSTextFieldCell" key="NSCell" id="598137039"> + <int key="NSCellFlags">343014977</int> + <int key="NSCellFlags2">272630784</int> + <string key="NSContents"/> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="925947608"/> + <bool key="NSDrawsBackground">YES</bool> + <object class="NSColor" key="NSBackgroundColor" id="123178460"> + <int key="NSColorSpace">6</int> + <string key="NSCatalogName">System</string> + <string key="NSColorName">textBackgroundColor</string> + <object class="NSColor" key="NSColor"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MQA</bytes> + </object> + </object> + <object class="NSColor" key="NSTextColor" id="444688007"> + <int key="NSColorSpace">6</int> + <string key="NSCatalogName">System</string> + <string key="NSColorName">textColor</string> + <reference key="NSColor" ref="1037439676"/> + </object> + </object> + </object> + <object class="NSTextField" id="907418310"> + <reference key="NSNextResponder" ref="647799232"/> + <int key="NSvFlags">266</int> + <string key="NSFrame">{{2, 36}, {371, 100}}</string> + <reference key="NSSuperview" ref="647799232"/> + <bool key="NSEnabled">YES</bool> + <object class="NSTextFieldCell" key="NSCell" id="361558600"> + <int key="NSCellFlags">-1805517311</int> + <int key="NSCellFlags2">272629760</int> + <string key="NSContents"/> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="907418310"/> + <bool key="NSDrawsBackground">YES</bool> + <reference key="NSBackgroundColor" ref="123178460"/> + <reference key="NSTextColor" ref="444688007"/> + </object> + </object> + <object class="NSButton" id="563361046"> + <reference key="NSNextResponder" ref="647799232"/> + <int key="NSvFlags">268</int> + <string key="NSFrame">{{0, 12}, {375, 18}}</string> + <reference key="NSSuperview" ref="647799232"/> + <bool key="NSEnabled">YES</bool> + <object class="NSButtonCell" key="NSCell" id="892557683"> + <int key="NSCellFlags">-2080244224</int> + <int key="NSCellFlags2">0</int> + <string key="NSContents">^IDS_BUGREPORT_INCLUDE_PAGE_IMAGE_CHKBOX</string> + <reference key="NSSupport" ref="702304060"/> + <reference key="NSControlView" ref="563361046"/> + <int key="NSButtonFlags">1211912703</int> + <int key="NSButtonFlags2">130</int> + <object class="NSCustomResource" key="NSNormalImage"> + <string key="NSClassName">NSImage</string> + <string key="NSResourceName">NSSwitch</string> + </object> + <object class="NSButtonImageSource" key="NSAlternateImage"> + <string key="NSImageName">NSSwitch</string> + </object> + <string key="NSAlternateContents"/> + <string key="NSKeyEquivalent"/> + <int key="NSPeriodicDelay">200</int> + <int key="NSPeriodicInterval">25</int> + </object> + </object> + </object> + <string key="NSFrame">{{1, 1}, {375, 231}}</string> + <reference key="NSSuperview" ref="577841338"/> + </object> + </object> + <string key="NSFrame">{{106, 50}, {377, 247}}</string> + <reference key="NSSuperview" ref="1006"/> + <string key="NSOffsets">{0, 0}</string> + <object class="NSTextFieldCell" key="NSTitleCell"> + <int key="NSCellFlags">67239424</int> + <int key="NSCellFlags2">0</int> + <string key="NSContents">Box</string> + <object class="NSFont" key="NSSupport"> + <string key="NSName">LucidaGrande</string> + <double key="NSSize">1.100000e+01</double> + <int key="NSfFlags">3100</int> + </object> + <reference key="NSBackgroundColor" ref="123178460"/> + <object class="NSColor" key="NSTextColor"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MCAwLjgwMDAwMDAxAA</bytes> + </object> + </object> + <reference key="NSContentView" ref="647799232"/> + <int key="NSBorderType">1</int> + <int key="NSBoxType">0</int> + <int key="NSTitlePosition">2</int> + <bool key="NSTransparent">NO</bool> + <bool key="NSFullyTransparent">YES</bool> + </object> + </object> + <string key="NSFrameSize">{500, 290}</string> + <reference key="NSSuperview"/> + </object> + <string key="NSScreenRect">{{0, 0}, {1680, 1028}}</string> + <string key="NSMaxSize">{3.40282e+38, 3.40282e+38}</string> + </object> + <object class="NSCustomObject" id="168145275"> + <string key="NSClassName">ChromeUILocalizer</string> + </object> + <object class="NSCustomObject" id="277131343"> + <string key="NSClassName">GTMUILocalizerAndLayoutTweaker</string> + </object> + </object> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <object class="NSMutableArray" key="connectionRecords"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBConnectionRecord"> + <object class="IBActionConnection" key="connection"> + <string key="label">cancel:</string> + <reference key="source" ref="1001"/> + <reference key="destination" ref="89080441"/> + </object> + <int key="connectionID">35</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">window</string> + <reference key="source" ref="1001"/> + <reference key="destination" ref="1005"/> + </object> + <int key="connectionID">37</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">localizer_</string> + <reference key="source" ref="277131343"/> + <reference key="destination" ref="168145275"/> + </object> + <int key="connectionID">42</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">uiObject_</string> + <reference key="source" ref="277131343"/> + <reference key="destination" ref="1005"/> + </object> + <int key="connectionID">43</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">value: pageURL_</string> + <reference key="source" ref="925947608"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector"> + <reference key="NSSource" ref="925947608"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">value: pageURL_</string> + <string key="NSBinding">value</string> + <string key="NSKeyPath">pageURL_</string> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">57</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">value: pageTitle_</string> + <reference key="source" ref="686336864"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector"> + <reference key="NSSource" ref="686336864"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">value: pageTitle_</string> + <string key="NSBinding">value</string> + <string key="NSKeyPath">pageTitle_</string> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">59</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">value: bugDescription_</string> + <reference key="source" ref="907418310"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector"> + <reference key="NSSource" ref="907418310"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">value: bugDescription_</string> + <string key="NSBinding">value</string> + <string key="NSKeyPath">bugDescription_</string> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">61</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">contentValues: bugTypeList</string> + <reference key="source" ref="304367917"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector" id="982383136"> + <reference key="NSSource" ref="304367917"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">contentValues: bugTypeList</string> + <string key="NSBinding">contentValues</string> + <string key="NSKeyPath">bugTypeList</string> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">98</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">selectedIndex: bugType</string> + <reference key="source" ref="304367917"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector"> + <reference key="NSSource" ref="304367917"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">selectedIndex: bugType</string> + <string key="NSBinding">selectedIndex</string> + <string key="NSKeyPath">bugType</string> + <reference key="NSPreviousConnector" ref="982383136"/> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">99</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBActionConnection" key="connection"> + <string key="label">sendReport:</string> + <reference key="source" ref="1001"/> + <reference key="destination" ref="833160383"/> + </object> + <int key="connectionID">100</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">viewToSlideAndResize_</string> + <reference key="source" ref="1006320362"/> + <reference key="destination" ref="577841338"/> + </object> + <int key="connectionID">109</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">viewToResize_</string> + <reference key="source" ref="1006320362"/> + <reference key="destination" ref="1005"/> + </object> + <int key="connectionID">110</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">sendReportButton</string> + <reference key="source" ref="1001"/> + <reference key="destination" ref="833160383"/> + </object> + <int key="connectionID">112</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">enabled: isPhishingReport</string> + <reference key="source" ref="907418310"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector"> + <reference key="NSSource" ref="907418310"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">enabled: isPhishingReport</string> + <string key="NSBinding">enabled</string> + <string key="NSKeyPath">isPhishingReport</string> + <object class="NSDictionary" key="NSOptions"> + <string key="NS.key.0">NSValueTransformerName</string> + <string key="NS.object.0">NSNegateBoolean</string> + </object> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">121</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">enabled: isPhishingReport</string> + <reference key="source" ref="563361046"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector" id="665911623"> + <reference key="NSSource" ref="563361046"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">enabled: isPhishingReport</string> + <string key="NSBinding">enabled</string> + <string key="NSKeyPath">isPhishingReport</string> + <object class="NSDictionary" key="NSOptions"> + <string key="NS.key.0">NSValueTransformerName</string> + <string key="NS.object.0">NSNegateBoolean</string> + </object> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">122</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBBindingConnection" key="connection"> + <string key="label">enabled2: disableScreenshot</string> + <reference key="source" ref="563361046"/> + <reference key="destination" ref="1001"/> + <object class="NSNibBindingConnector" key="connector"> + <reference key="NSSource" ref="563361046"/> + <reference key="NSDestination" ref="1001"/> + <string key="NSLabel">enabled2: disableScreenshot</string> + <string key="NSBinding">enabled2</string> + <string key="NSKeyPath">disableScreenshot</string> + <object class="NSDictionary" key="NSOptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSMutableArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>NSMultipleValuesPlaceholder</string> + <string>NSNoSelectionPlaceholder</string> + <string>NSNotApplicablePlaceholder</string> + <string>NSNullPlaceholder</string> + <string>NSValueTransformerName</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="-1" id="7"/> + <reference ref="7"/> + <reference ref="7"/> + <reference ref="7"/> + <string>NSNegateBoolean</string> + </object> + </object> + <reference key="NSPreviousConnector" ref="665911623"/> + <int key="NSNibBindingConnectorVersion">2</int> + </object> + </object> + <int key="connectionID">123</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">delegate</string> + <reference key="source" ref="1060400312"/> + <reference key="destination" ref="1001"/> + </object> + <int key="connectionID">128</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBOutletConnection" key="connection"> + <string key="label">delegate</string> + <reference key="source" ref="1005"/> + <reference key="destination" ref="1001"/> + </object> + <int key="connectionID">129</int> + </object> + </object> + <object class="IBMutableOrderedSet" key="objectRecords"> + <object class="NSArray" key="orderedObjects"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <object class="NSArray" key="object" id="371217840"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <reference key="children" ref="1000"/> + <nil key="parent"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-2</int> + <reference key="object" ref="1001"/> + <reference key="parent" ref="371217840"/> + <string type="base64-UTF8" key="objectName">RmlsZSdzIE93bmVyA</string> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-1</int> + <reference key="object" ref="1003"/> + <reference key="parent" ref="371217840"/> + <string key="objectName">First Responder</string> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-3</int> + <reference key="object" ref="1004"/> + <reference key="parent" ref="371217840"/> + <string key="objectName">Application</string> + </object> + <object class="IBObjectRecord"> + <int key="objectID">1</int> + <reference key="object" ref="1005"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="1006"/> + </object> + <reference key="parent" ref="371217840"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">2</int> + <reference key="object" ref="1006"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="1006320362"/> + <reference ref="577841338"/> + <reference ref="97454414"/> + </object> + <reference key="parent" ref="1005"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">40</int> + <reference key="object" ref="168145275"/> + <reference key="parent" ref="371217840"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">41</int> + <reference key="object" ref="277131343"/> + <reference key="parent" ref="371217840"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">95</int> + <reference key="object" ref="97454414"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="89080441"/> + <reference ref="833160383"/> + </object> + <reference key="parent" ref="1006"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">25</int> + <reference key="object" ref="89080441"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="100321947"/> + </object> + <reference key="parent" ref="97454414"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">26</int> + <reference key="object" ref="100321947"/> + <reference key="parent" ref="89080441"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">27</int> + <reference key="object" ref="833160383"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="629834119"/> + </object> + <reference key="parent" ref="97454414"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">28</int> + <reference key="object" ref="629834119"/> + <reference key="parent" ref="833160383"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">104</int> + <reference key="object" ref="1006320362"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="785984542"/> + <reference ref="824407095"/> + <reference ref="319457361"/> + <reference ref="172513261"/> + </object> + <reference key="parent" ref="1006"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">3</int> + <reference key="object" ref="824407095"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="157068629"/> + </object> + <reference key="parent" ref="1006320362"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">4</int> + <reference key="object" ref="157068629"/> + <reference key="parent" ref="824407095"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">5</int> + <reference key="object" ref="319457361"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="89599916"/> + </object> + <reference key="parent" ref="1006320362"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">6</int> + <reference key="object" ref="89599916"/> + <reference key="parent" ref="319457361"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">7</int> + <reference key="object" ref="785984542"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="677642034"/> + </object> + <reference key="parent" ref="1006320362"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">8</int> + <reference key="object" ref="677642034"/> + <reference key="parent" ref="785984542"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">9</int> + <reference key="object" ref="172513261"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="610895328"/> + </object> + <reference key="parent" ref="1006320362"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">10</int> + <reference key="object" ref="610895328"/> + <reference key="parent" ref="172513261"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">108</int> + <reference key="object" ref="577841338"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="304367917"/> + <reference ref="925947608"/> + <reference ref="563361046"/> + <reference ref="907418310"/> + <reference ref="686336864"/> + </object> + <reference key="parent" ref="1006"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">11</int> + <reference key="object" ref="686336864"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="190256621"/> + </object> + <reference key="parent" ref="577841338"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">12</int> + <reference key="object" ref="190256621"/> + <reference key="parent" ref="686336864"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">19</int> + <reference key="object" ref="304367917"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="405291569"/> + </object> + <reference key="parent" ref="577841338"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">20</int> + <reference key="object" ref="405291569"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="1060400312"/> + </object> + <reference key="parent" ref="304367917"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">21</int> + <reference key="object" ref="1060400312"/> + <reference key="parent" ref="405291569"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">13</int> + <reference key="object" ref="925947608"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="598137039"/> + </object> + <reference key="parent" ref="577841338"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">14</int> + <reference key="object" ref="598137039"/> + <reference key="parent" ref="925947608"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">15</int> + <reference key="object" ref="907418310"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="361558600"/> + </object> + <reference key="parent" ref="577841338"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">16</int> + <reference key="object" ref="361558600"/> + <reference key="parent" ref="907418310"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">17</int> + <reference key="object" ref="563361046"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="892557683"/> + </object> + <reference key="parent" ref="577841338"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">18</int> + <reference key="object" ref="892557683"/> + <reference key="parent" ref="563361046"/> + </object> + </object> + </object> + <object class="NSMutableDictionary" key="flattenedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSMutableArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>-1.IBPluginDependency</string> + <string>-2.IBPluginDependency</string> + <string>-3.IBPluginDependency</string> + <string>1.IBEditorWindowLastContentRect</string> + <string>1.IBPluginDependency</string> + <string>1.IBWindowTemplateEditedContentRect</string> + <string>1.NSWindowTemplate.visibleAtLaunch</string> + <string>1.WindowOrigin</string> + <string>1.editorWindowContentRectSynchronizationRect</string> + <string>10.IBPluginDependency</string> + <string>11.IBPluginDependency</string> + <string>12.IBPluginDependency</string> + <string>13.IBPluginDependency</string> + <string>14.IBPluginDependency</string> + <string>15.IBPluginDependency</string> + <string>16.IBPluginDependency</string> + <string>17.IBPluginDependency</string> + <string>18.IBPluginDependency</string> + <string>19.IBPluginDependency</string> + <string>2.IBPluginDependency</string> + <string>20.IBPluginDependency</string> + <string>21.IBEditorWindowLastContentRect</string> + <string>21.IBPluginDependency</string> + <string>25.IBPluginDependency</string> + <string>26.IBPluginDependency</string> + <string>27.IBPluginDependency</string> + <string>28.IBPluginDependency</string> + <string>3.IBPluginDependency</string> + <string>4.IBPluginDependency</string> + <string>40.IBPluginDependency</string> + <string>41.IBPluginDependency</string> + <string>5.IBPluginDependency</string> + <string>6.IBPluginDependency</string> + <string>7.IBPluginDependency</string> + <string>8.IBPluginDependency</string> + <string>9.IBPluginDependency</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>{{883, 600}, {500, 290}}</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>{{883, 600}, {500, 290}}</string> + <integer value="1"/> + <string>{196, 240}</string> + <string>{{357, 418}, {480, 270}}</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>{{1042, 693}, {377, 6}}</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + <string>com.apple.InterfaceBuilder.CocoaPlugin</string> + </object> + </object> + <object class="NSMutableDictionary" key="unlocalizedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="activeLocalization"/> + <object class="NSMutableDictionary" key="localizations"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="sourceID"/> + <int key="maxID">130</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"> + <object class="NSMutableArray" key="referencedPartialClassDescriptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBPartialClassDescription"> + <string key="className">BugReportWindowController</string> + <string key="superclassName">NSWindowController</string> + <object class="NSMutableDictionary" key="actions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSMutableArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>cancel:</string> + <string>sendReport:</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>id</string> + <string>id</string> + </object> + </object> + <object class="NSMutableDictionary" key="outlets"> + <string key="NS.key.0">sendReportButton</string> + <string key="NS.object.0">NSButton</string> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">browser/cocoa/bug_report_window_controller.h</string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">ChromeUILocalizer</string> + <string key="superclassName">GTMUILocalizer</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">browser/cocoa/ui_localizer.h</string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">GTMUILocalizer</string> + <string key="superclassName">NSObject</string> + <object class="NSMutableDictionary" key="outlets"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSMutableArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>otherObjectToLocalize_</string> + <string>owner_</string> + <string>yetAnotherObjectToLocalize_</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>id</string> + <string>id</string> + <string>id</string> + </object> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">../third_party/GTM/AppKit/GTMUILocalizer.h</string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">GTMUILocalizerAndLayoutTweaker</string> + <string key="superclassName">NSObject</string> + <object class="NSMutableDictionary" key="outlets"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSMutableArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>localizerOwner_</string> + <string>localizer_</string> + <string>uiObject_</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>id</string> + <string>GTMUILocalizer</string> + <string>id</string> + </object> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier" id="928089158"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">../third_party/GTM/AppKit/GTMUILocalizerAndLayoutTweaker.h</string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">GTMWidthBasedTweaker</string> + <string key="superclassName">NSView</string> + <object class="NSMutableDictionary" key="outlets"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSMutableArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>viewToResize_</string> + <string>viewToSlideAndResize_</string> + <string>viewToSlide_</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>id</string> + <string>NSView</string> + <string>NSView</string> + </object> + </object> + <reference key="sourceIdentifier" ref="928089158"/> + </object> + <object class="IBPartialClassDescription"> + <string key="className">NSObject</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">browser/cocoa/status_bubble_mac.h</string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">NSObject</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">browser/cocoa/tab_strip_model_observer_bridge.h</string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">NSWindow</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBProjectSource</string> + <string key="minorKey">browser/cocoa/nswindow_local_state.h</string> + </object> + </object> + </object> + </object> + <int key="IBDocument.localizationMode">0</int> + <string key="IBDocument.LastKnownRelativeProjectPath">../../chrome.xcodeproj</string> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + </data> +</archive> diff --git a/chrome/browser/app_controller_mac.mm b/chrome/browser/app_controller_mac.mm index d9c4082..c173740 100644 --- a/chrome/browser/app_controller_mac.mm +++ b/chrome/browser/app_controller_mac.mm @@ -21,6 +21,7 @@ #import "chrome/browser/cocoa/bookmark_menu_bridge.h" #import "chrome/browser/cocoa/browser_window_cocoa.h" #import "chrome/browser/cocoa/browser_window_controller.h" +#import "chrome/browser/cocoa/bug_report_window_controller.h" #import "chrome/browser/cocoa/history_menu_bridge.h" #import "chrome/browser/cocoa/clear_browsing_data_controller.h" #import "chrome/browser/cocoa/encoding_menu_controller_delegate_mac.h" @@ -528,6 +529,17 @@ static bool g_is_opening_new_window = false; case IDC_HELP_PAGE: Browser::OpenHelpWindow(defaultProfile); break; + case IDC_REPORT_BUG: { + Browser* browser = BrowserList::GetLastActive(); + TabContents* current_tab = (browser != NULL) ? + browser->GetSelectedTabContents() : NULL; + BugReportWindowController* controller = + [[BugReportWindowController alloc] + initWithTabContents:current_tab + profile:[self defaultProfile]]; + [controller runModalDialog]; + break; + } }; } @@ -563,6 +575,7 @@ static bool g_is_opening_new_window = false; menuState_->UpdateCommandEnabled(IDC_SHOW_HISTORY, true); menuState_->UpdateCommandEnabled(IDC_SHOW_DOWNLOADS, true); menuState_->UpdateCommandEnabled(IDC_HELP_PAGE, true); + menuState_->UpdateCommandEnabled(IDC_REPORT_BUG, true); // TODO(pinkerton): ...more to come... } diff --git a/chrome/browser/cocoa/browser_window_cocoa.mm b/chrome/browser/cocoa/browser_window_cocoa.mm index 398948e..9eee4c7 100644 --- a/chrome/browser/cocoa/browser_window_cocoa.mm +++ b/chrome/browser/cocoa/browser_window_cocoa.mm @@ -9,6 +9,7 @@ #include "chrome/browser/bookmarks/bookmark_utils.h" #include "chrome/browser/cocoa/browser_window_cocoa.h" #import "chrome/browser/cocoa/browser_window_controller.h" +#import "chrome/browser/cocoa/bug_report_window_controller.h" #import "chrome/browser/cocoa/clear_browsing_data_controller.h" #import "chrome/browser/cocoa/download_shelf_controller.h" #import "chrome/browser/cocoa/html_dialog_window_controller.h" @@ -246,7 +247,14 @@ DownloadShelf* BrowserWindowCocoa::GetDownloadShelf() { } void BrowserWindowCocoa::ShowReportBugDialog() { - NOTIMPLEMENTED(); + TabContents* current_tab = browser_->GetSelectedTabContents(); + if (current_tab && current_tab->controller().GetActiveEntry()) { + BugReportWindowController* controller = + [[BugReportWindowController alloc] + initWithTabContents:current_tab + profile:browser_->profile()]; + [controller runModalDialog]; + } } void BrowserWindowCocoa::ShowClearBrowsingDataDialog() { diff --git a/chrome/browser/cocoa/bug_report_window_controller.h b/chrome/browser/cocoa/bug_report_window_controller.h new file mode 100644 index 0000000..93eea0a --- /dev/null +++ b/chrome/browser/cocoa/bug_report_window_controller.h @@ -0,0 +1,88 @@ +// Copyright (c) 2009 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef CHROME_BROWSER_COCOA_BUG_REPORT_WINDOW_CONTROLLER_H_ +#define CHROME_BROWSER_COCOA_BUG_REPORT_WINDOW_CONTROLLER_H_ + +#import <Cocoa/Cocoa.h> + +#include <vector> + +#include "base/scoped_ptr.h" + +class Profile; +class TabContents; + +// A window controller for managing the "Report Bug" feature. Modally +// presents a dialog that allows the user to either file a bug report on +// a broken page, or go directly to Google's "Report Phishing" page and +// file a report there. +@interface BugReportWindowController : NSWindowController { + @private + TabContents* currentTab_; // Weak, owned by browser. + Profile* profile_; // Weak, owned by browser. + + // Holds screenshot of current tab. + std::vector<unsigned char> pngData_; + + // Values bound to data in the dialog box. These values cannot be boxed in + // scoped_nsobjects because we use them for bindings. + NSString* bugDescription_; // Strong. + NSUInteger bugType_; + NSString* pageTitle_; // Strong. + NSString* pageURL_; // Strong. + + // We keep a pointer to this button so we can change its title. + NSButton* sendReportButton_; // Weak. + + BOOL sendScreenshot_; + + // Disable screenshot if no browser window is open. + BOOL disableScreenshot_; + + // Menu for the bug type popup button. We create it here instead of in + // IB so that we can nicely check whether the phishing page is selected, + // and so that we can create a menu without "page" options when no browser + // window is open. + NSArray* bugTypeList_; // Strong. +} + +// Initialize with the contents of the tab to be reported as buggy / wrong. +// If dialog is called without an open window, currentTab may be null; in +// that case, a dialog is opened with options for reporting a bugs not +// related to a specific page. Profile is passed to BugReportUtil, who +// will not send a report if the value is null. +- (id)initWithTabContents:(TabContents*)currentTab profile:(Profile*)profile; + +// Run the dialog with an application-modal event loop. If the user accepts, +// send the report of the bug or broken web site. +- (void)runModalDialog; + +// IBActions for the dialog buttons. +- (IBAction)sendReport:(id)sender; +- (IBAction)cancel:(id)sender; + +// YES if the user has selected the phishing report option. +- (BOOL)isPhishingReport; + +// The "send report" button may need to change its title to reflect that it's +// bouncing to the phish report page instead of sending a report directly +// from the dialog box (or vice versa). Observe the menu of bug types +// and change the button title along with the selected bug. +- (void)menu:(NSMenu *)menu willHighlightItem:(NSMenuItem *)item; + +// Properties for bindings. +@property (copy, nonatomic) NSString* bugDescription; +@property NSUInteger bugType; +@property (copy, nonatomic) NSString* pageTitle; +@property (copy, nonatomic) NSString* pageURL; +@property (assign, nonatomic) IBOutlet NSButton* sendReportButton; +@property BOOL sendScreenshot; +@property BOOL disableScreenshot; +@property (readonly, nonatomic) NSArray* bugTypeList; + +@end + +#endif // CHROME_BROWSER_COCOA_BUG_REPORT_WINDOW_CONTROLLER_H_ + diff --git a/chrome/browser/cocoa/bug_report_window_controller.mm b/chrome/browser/cocoa/bug_report_window_controller.mm new file mode 100644 index 0000000..6fd7e5d --- /dev/null +++ b/chrome/browser/cocoa/bug_report_window_controller.mm @@ -0,0 +1,157 @@ +// Copyright (c) 2009 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#import "chrome/browser/cocoa/bug_report_window_controller.h" + +#include "app/l10n_util_mac.h" +#include "base/mac_util.h" +#include "base/sys_string_conversions.h" +#include "chrome/browser/bug_report_util.h" +#include "chrome/browser/tab_contents/tab_contents.h" +#include "chrome/browser/tab_contents/tab_contents_view.h" +#include "grit/chromium_strings.h" +#include "grit/generated_resources.h" +#include "third_party/GTM/AppKit/GTMUILocalizerAndLayoutTweaker.h" + +@implementation BugReportWindowController + +@synthesize bugDescription = bugDescription_; +@synthesize bugType = bugType_; +@synthesize pageURL = pageURL_; +@synthesize pageTitle = pageTitle_; +@synthesize sendReportButton = sendReportButton_; +@synthesize sendScreenshot = sendScreenshot_; +@synthesize disableScreenshot = disableScreenshot_; +@synthesize bugTypeList = bugTypeList_; + +- (id)initWithTabContents:(TabContents*)currentTab + profile:(Profile*)profile { + NSString* nibpath = [mac_util::MainAppBundle() pathForResource:@"ReportBug" + ofType:@"nib"]; + if ((self = [super initWithWindowNibPath:nibpath owner:self])) { + currentTab_ = currentTab; + profile_ = profile; + [self setBugDescription:@""]; + + if (currentTab_ != NULL) { + // Get data from current tab, if one exists. This dialog could be called + // from the main menu with no tab contents, so currentTab_ is not + // guaranteed to be non-NULL. + // TODO(mirandac): This dialog should be a tab-modal sheet if a browser + // window exists. + [self setSendScreenshot:YES]; + [self setDisableScreenshot:NO]; + bugTypeList_ = [[NSArray alloc] initWithObjects: + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_PAGE_WONT_LOAD), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_PAGE_LOOKS_ODD), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_PHISHING_PAGE), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_CANT_SIGN_IN), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_CHROME_MISBEHAVES), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_SOMETHING_MISSING), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_BROWSER_CRASH), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_OTHER_PROBLEM), + nil]; + [self setPageURL:base::SysUTF8ToNSString( + currentTab_->controller().GetActiveEntry()->url().spec())]; + [self setPageTitle:base::SysUTF16ToNSString(currentTab_->GetTitle())]; + mac_util::GrabWindowSnapshot( + currentTab_->view()->GetTopLevelNativeWindow(), &pngData_); + } else { + // If no current tab exists, create a menu without the "broken page" + // options, with page URL and title empty, and screenshot disabled. + [self setSendScreenshot:NO]; + [self setDisableScreenshot:YES]; + bugTypeList_ = [[NSArray alloc] initWithObjects: + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_CHROME_MISBEHAVES), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_SOMETHING_MISSING), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_BROWSER_CRASH), + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_OTHER_PROBLEM), + nil]; + // Because "Report Bug" is being called with no browser open in this + // case, make URL and title empty. + [self setPageURL:@""]; + [self setPageTitle:@""]; + } + } + return self; +} + +- (void)dealloc { + [pageURL_ release]; + [pageTitle_ release]; + [bugDescription_ release]; + [bugTypeList_ release]; + [super dealloc]; +} + +// Delegate callback so that closing the window deletes the controller. +- (void)windowWillClose:(NSNotification*)notification { + [self autorelease]; +} + +- (void)closeDialog { + [NSApp stopModal]; + [[self window] close]; +} + +- (void)runModalDialog { + [NSApp runModalForWindow:[self window]]; +} + +- (IBAction)sendReport:(id)sender { + if ([self isPhishingReport]) { + BugReportUtil::ReportPhishing(currentTab_, + base::SysNSStringToUTF8(pageURL_)); + } else { + BugReportUtil::SendReport( + profile_, + base::SysNSStringToUTF8(pageTitle_), + bugType_, + base::SysNSStringToUTF8(pageURL_), + base::SysNSStringToUTF8(bugDescription_), + sendScreenshot_ && !pngData_.empty() ? + reinterpret_cast<const char *>(&(pngData_[0])) : NULL, + pngData_.size()); + } + [self closeDialog]; +} + +- (IBAction)cancel:(id)sender { + [self closeDialog]; +} + +- (BOOL)isPhishingReport { + return bugType_ == [bugTypeList_ indexOfObject: + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_PHISHING_PAGE)]; +} + +- (void)menu:(NSMenu *)menu willHighlightItem:(NSMenuItem *)item { + NSString* buttonTitle = [[item title] isEqualToString: + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_PHISHING_PAGE)] ? + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_SEND_PHISHING_REPORT) : + l10n_util::GetNSStringWithFixup(IDS_BUGREPORT_SEND_REPORT); + if (![buttonTitle isEqualToString:[sendReportButton_ title]]) { + [sendReportButton_ setTitle:buttonTitle]; + CGFloat deltaWidth = + [GTMUILocalizerAndLayoutTweaker sizeToFitView:sendReportButton_].width; + NSRect newButtonFrame = [sendReportButton_ frame]; + newButtonFrame.origin.x -= deltaWidth; + [sendReportButton_ setFrame:newButtonFrame]; + } +} + +// BugReportWindowController needs to change the title of the Send Report +// button when the user chooses the phishing bug type, so we need to bind +// the function that changes the button title to the bug type key. ++ (NSSet*)keyPathsForValuesAffectingValueForKey:(NSString*)key { + NSSet* paths = [super keyPathsForValuesAffectingValueForKey:key]; + if ([key isEqualToString:@"isPhishingReport"]) { + paths = [paths setByAddingObject:@"bugType"]; + } + return paths; +} + +@end + + diff --git a/chrome/browser/cocoa/bug_report_window_controller_unittest.mm b/chrome/browser/cocoa/bug_report_window_controller_unittest.mm new file mode 100644 index 0000000..6b15c4a --- /dev/null +++ b/chrome/browser/cocoa/bug_report_window_controller_unittest.mm @@ -0,0 +1,71 @@ +// Copyright (c) 2009 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#import <Cocoa/Cocoa.h> + +#include "base/ref_counted.h" +#import "chrome/browser/cocoa/bug_report_window_controller.h" +#include "chrome/browser/renderer_host/site_instance.h" +#include "chrome/browser/renderer_host/test/test_render_view_host.h" +#include "chrome/browser/tab_contents/test_tab_contents.h" +#include "chrome/browser/profile.h" + +namespace { + +class BugReportWindowControllerUnittest : public RenderViewHostTestHarness { +}; + +TEST_F(BugReportWindowControllerUnittest, ReportBugWithNewTabPageOpen) { + // Create a "chrome://newtab" test tab. SiteInstance will be deleted when + // tabContents is deleted. + SiteInstance* instance = + SiteInstance::CreateSiteInstance(profile_.get()); + TestTabContents* tabContents = new TestTabContents(profile_.get(), + instance); + tabContents->controller().LoadURL(GURL("chrome://newtab"), + GURL(), PageTransition::START_PAGE); + + BugReportWindowController* controller = [[BugReportWindowController alloc] + initWithTabContents:tabContents + profile:profile_.get()]; + + // The phishing report bug is stored at index 2 in the Report Bug dialog. + [controller setBugType:2]; + EXPECT_TRUE([controller isPhishingReport]); + [controller setBugType:1]; + EXPECT_FALSE([controller isPhishingReport]); + + // Make sure that the tab was correctly recorded. + EXPECT_TRUE([[controller pageURL] isEqualToString:@"chrome://newtab/"]); + EXPECT_TRUE([[controller pageTitle] isEqualToString:@"New Tab"]); + + // When we call "report bug" with non-empty tab contents, all menu options + // should be available, and we should send screenshot by default. + EXPECT_EQ([[controller bugTypeList] count], 8U); + EXPECT_TRUE([controller sendScreenshot]); + + delete tabContents; + [controller release]; +} + +TEST_F(BugReportWindowControllerUnittest, ReportBugWithNoWindowOpen) { + BugReportWindowController* controller = [[BugReportWindowController alloc] + initWithTabContents:NULL + profile:profile_.get()]; + + // Make sure that no page title or URL are recorded. + EXPECT_TRUE([[controller pageURL] isEqualToString:@""]); + EXPECT_TRUE([[controller pageTitle] isEqualToString:@""]); + + // When we call "report bug" with empty tab contents, only menu options + // that don't refer to a specific page should be available, and the send + // screenshot option should be turned off. + EXPECT_EQ([[controller bugTypeList] count], 4U); + EXPECT_FALSE([controller sendScreenshot]); + + [controller release]; +} + +} // namespace + diff --git a/chrome/chrome.gyp b/chrome/chrome.gyp index 59946bb..913dd6d 100755 --- a/chrome/chrome.gyp +++ b/chrome/chrome.gyp @@ -1078,6 +1078,8 @@ 'browser/cocoa/browser_window_controller.mm', 'browser/cocoa/bubble_view.h', 'browser/cocoa/bubble_view.mm', + 'browser/cocoa/bug_report_window_controller.h', + 'browser/cocoa/bug_report_window_controller.mm', 'browser/cocoa/chrome_browser_window.h', 'browser/cocoa/chrome_browser_window.mm', 'browser/cocoa/chrome_event_processing_window.h', @@ -2628,6 +2630,7 @@ 'app/nibs/MainMenu.xib', 'app/nibs/PageInfo.xib', 'app/nibs/Preferences.xib', + 'app/nibs/ReportBug.xib', 'app/nibs/SaveAccessoryView.xib', 'app/nibs/TabView.xib', 'app/nibs/TaskManager.xib', @@ -4476,6 +4479,7 @@ 'browser/cocoa/browser_window_cocoa_unittest.mm', 'browser/cocoa/browser_window_controller_unittest.mm', 'browser/cocoa/bubble_view_unittest.mm', + 'browser/cocoa/bug_report_window_controller_unittest.mm', 'browser/cocoa/chrome_browser_window_unittest.mm', 'browser/cocoa/chrome_event_processing_window_unittest.mm', 'browser/cocoa/clear_browsing_data_controller_unittest.mm', @@ -5684,6 +5688,7 @@ 'app/nibs/MainMenu.xib', 'app/nibs/PageInfo.xib', 'app/nibs/Preferences.xib', + 'app/nibs/ReportBug.xib', 'app/nibs/SaveAccessoryView.xib', 'app/nibs/TabContents.xib', 'app/nibs/TabView.xib', |