Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5908)

Unified Diff: chrome/browser/ui/cocoa/previewable_contents_controller.mm

Issue 6358008: [Mac] Organize some files into chrome/browser/ui/cocoa/tab_contents/.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/previewable_contents_controller.mm
===================================================================
--- chrome/browser/ui/cocoa/previewable_contents_controller.mm (revision 71953)
+++ chrome/browser/ui/cocoa/previewable_contents_controller.mm (working copy)
@@ -1,52 +0,0 @@
-// Copyright (c) 2010 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/ui/cocoa/previewable_contents_controller.h"
-
-#include "base/logging.h"
-#include "base/mac/mac_util.h"
-#include "chrome/browser/tab_contents/tab_contents.h"
-
-@implementation PreviewableContentsController
-
-@synthesize activeContainer = activeContainer_;
-
-- (id)init {
- if ((self = [super initWithNibName:@"PreviewableContents"
- bundle:base::mac::MainAppBundle()])) {
- }
- return self;
-}
-
-- (void)showPreview:(TabContents*)preview {
- DCHECK(preview);
-
- // Remove any old preview contents before showing the new one.
- if (previewContents_)
- [previewContents_->GetNativeView() removeFromSuperview];
-
- previewContents_ = preview;
- NSView* previewView = previewContents_->GetNativeView();
- [previewView setFrame:[[self view] bounds]];
-
- // Hide the active container and add the preview contents.
- [activeContainer_ setHidden:YES];
- [[self view] addSubview:previewView];
-}
-
-- (void)hidePreview {
- DCHECK(previewContents_);
-
- // Remove the preview contents and reshow the active container.
- [previewContents_->GetNativeView() removeFromSuperview];
- [activeContainer_ setHidden:NO];
-
- previewContents_ = nil;
-}
-
-- (BOOL)isShowingPreview {
- return previewContents_ != nil;
-}
-
-@end

Powered by Google App Engine
This is Rietveld 408576698