| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_name_folder_controller.h" | 5 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_name_folder_controller.h" |
| 6 | 6 |
| 7 #include "base/mac/bundle_locations.h" | 7 #include "base/mac/bundle_locations.h" |
| 8 #include "base/strings/sys_string_conversions.h" | 8 #include "base/strings/sys_string_conversions.h" |
| 9 #include "chrome/browser/bookmarks/bookmark_model_factory.h" | 9 #include "chrome/browser/bookmarks/bookmark_model_factory.h" |
| 10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
| 11 #include "chrome/browser/ui/cocoa/bookmarks/bookmark_model_observer_for_cocoa.h" | 11 #include "chrome/browser/ui/cocoa/bookmarks/bookmark_model_observer_for_cocoa.h" |
| 12 #include "chrome/grit/generated_resources.h" | 12 #include "chrome/grit/generated_resources.h" |
| 13 #include "ui/base/l10n/l10n_util.h" | 13 #include "ui/base/l10n/l10n_util.h" |
| 14 #include "ui/base/l10n/l10n_util_mac.h" | 14 #include "ui/base/l10n/l10n_util_mac.h" |
| 15 | 15 |
| 16 using bookmarks::BookmarkModel; | 16 using bookmarks::BookmarkModel; |
| 17 using bookmarks::BookmarkNode; |
| 17 | 18 |
| 18 @implementation BookmarkNameFolderController | 19 @implementation BookmarkNameFolderController |
| 19 | 20 |
| 20 // Common initializer (private). | 21 // Common initializer (private). |
| 21 - (id)initWithParentWindow:(NSWindow*)window | 22 - (id)initWithParentWindow:(NSWindow*)window |
| 22 profile:(Profile*)profile | 23 profile:(Profile*)profile |
| 23 node:(const BookmarkNode*)node | 24 node:(const BookmarkNode*)node |
| 24 parent:(const BookmarkNode*)parent | 25 parent:(const BookmarkNode*)parent |
| 25 newIndex:(int)newIndex { | 26 newIndex:(int)newIndex { |
| 26 NSString* nibpath = [base::mac::FrameworkBundle() | 27 NSString* nibpath = [base::mac::FrameworkBundle() |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 125 | 126 |
| 126 - (void)setFolderName:(NSString*)name { | 127 - (void)setFolderName:(NSString*)name { |
| 127 [nameField_ setStringValue:name]; | 128 [nameField_ setStringValue:name]; |
| 128 } | 129 } |
| 129 | 130 |
| 130 - (NSButton*)okButton { | 131 - (NSButton*)okButton { |
| 131 return okButton_; | 132 return okButton_; |
| 132 } | 133 } |
| 133 | 134 |
| 134 @end // BookmarkNameFolderController | 135 @end // BookmarkNameFolderController |
| OLD | NEW |