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

Unified Diff: views/widget/native_widget_aura.cc

Issue 7749020: Revert 98306 - Create a new views_aura_desktop. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 4 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
« no previous file with comments | « views/widget/native_widget_aura.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/widget/native_widget_aura.cc
===================================================================
--- views/widget/native_widget_aura.cc (revision 98311)
+++ views/widget/native_widget_aura.cc (working copy)
@@ -4,20 +4,12 @@
#include "views/widget/native_widget_aura.h"
-#include "aura/window.h"
-#include "ui/gfx/canvas.h"
-#include "ui/gfx/compositor/layer.h"
-#include "views/widget/native_widget_delegate.h"
-
namespace views {
////////////////////////////////////////////////////////////////////////////////
// NativeWidgetAura, public:
-NativeWidgetAura::NativeWidgetAura(internal::NativeWidgetDelegate* delegate)
- : delegate_(delegate),
- ALLOW_THIS_IN_INITIALIZER_LIST(window_(new aura::Window(this))) {
- window_->set_id(1200);
+NativeWidgetAura::NativeWidgetAura(internal::NativeWidgetDelegate* delegate) {
}
NativeWidgetAura::~NativeWidgetAura() {
@@ -27,46 +19,36 @@
// NativeWidgetAura, internal::NativeWidgetPrivate implementation:
void NativeWidgetAura::InitNativeWidget(const Widget::InitParams& params) {
- window_->Init();
- window_->SetBounds(params.bounds, 0);
- window_->SetParent(params.parent);
- // TODO(beng): do this some other way.
- delegate_->OnNativeWidgetSizeChanged(params.bounds.size());
- window_->SetVisibility(aura::Window::VISIBILITY_SHOWN);
}
NonClientFrameView* NativeWidgetAura::CreateNonClientFrameView() {
- NOTIMPLEMENTED();
return NULL;
}
void NativeWidgetAura::UpdateFrameAfterFrameChange() {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::ShouldUseNativeFrame() const {
- NOTIMPLEMENTED();
return false;
}
void NativeWidgetAura::FrameTypeChanged() {
- NOTIMPLEMENTED();
}
Widget* NativeWidgetAura::GetWidget() {
- return delegate_->AsWidget();
+ return NULL;
}
const Widget* NativeWidgetAura::GetWidget() const {
- return delegate_->AsWidget();
+ return NULL;
}
gfx::NativeView NativeWidgetAura::GetNativeView() const {
- return window_;
+ return NULL;
}
gfx::NativeWindow NativeWidgetAura::GetNativeWindow() const {
- return window_;
+ return NULL;
}
Widget* NativeWidgetAura::GetTopLevelWidget() {
@@ -75,133 +57,106 @@
}
const ui::Compositor* NativeWidgetAura::GetCompositor() const {
- return window_->layer()->compositor();
+ return NULL;
}
ui::Compositor* NativeWidgetAura::GetCompositor() {
- return window_->layer()->compositor();
+ return NULL;
}
void NativeWidgetAura::MarkLayerDirty() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::CalculateOffsetToAncestorWithLayer(gfx::Point* offset,
View** ancestor) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::ViewRemoved(View* view) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetNativeWindowProperty(const char* name, void* value) {
- NOTIMPLEMENTED();
}
void* NativeWidgetAura::GetNativeWindowProperty(const char* name) const {
- NOTIMPLEMENTED();
return NULL;
}
TooltipManager* NativeWidgetAura::GetTooltipManager() const {
- NOTIMPLEMENTED();
return NULL;
}
bool NativeWidgetAura::IsScreenReaderActive() const {
- NOTIMPLEMENTED();
return false;
}
void NativeWidgetAura::SendNativeAccessibilityEvent(
View* view,
ui::AccessibilityTypes::Event event_type) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetMouseCapture() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::ReleaseMouseCapture() {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::HasMouseCapture() const {
- NOTIMPLEMENTED();
return false;
}
InputMethod* NativeWidgetAura::CreateInputMethod() {
- NOTIMPLEMENTED();
return NULL;
}
void NativeWidgetAura::CenterWindow(const gfx::Size& size) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::GetWindowBoundsAndMaximizedState(gfx::Rect* bounds,
bool* maximized) const {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetWindowTitle(const std::wstring& title) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetWindowIcons(const SkBitmap& window_icon,
const SkBitmap& app_icon) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetAccessibleName(const std::wstring& name) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetAccessibleRole(ui::AccessibilityTypes::Role role) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetAccessibleState(ui::AccessibilityTypes::State state) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::BecomeModal() {
- NOTIMPLEMENTED();
}
gfx::Rect NativeWidgetAura::GetWindowScreenBounds() const {
- // TODO(beng): ensure screen bounds
- return window_->bounds();
+ return gfx::Rect();
}
gfx::Rect NativeWidgetAura::GetClientAreaScreenBounds() const {
- // TODO(beng):
- return window_->bounds();
+ return gfx::Rect();
}
gfx::Rect NativeWidgetAura::GetRestoredBounds() const {
- // TODO(beng):
- return window_->bounds();
+ return gfx::Rect();
}
void NativeWidgetAura::SetBounds(const gfx::Rect& bounds) {
- window_->SetBounds(bounds, 0);
}
void NativeWidgetAura::SetSize(const gfx::Size& size) {
- window_->SetBounds(gfx::Rect(window_->bounds().origin(), size), 0);
}
void NativeWidgetAura::SetBoundsConstrained(const gfx::Rect& bounds,
- Widget* other_widget) {
- NOTIMPLEMENTED();
+ Widget* other_widget) {
}
void NativeWidgetAura::MoveAbove(gfx::NativeView native_view) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::MoveToTop() {
@@ -209,212 +164,105 @@
}
void NativeWidgetAura::SetShape(gfx::NativeRegion region) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::Close() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::CloseNow() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::EnableClose(bool enable) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::Show() {
- window_->SetVisibility(aura::Window::VISIBILITY_SHOWN);
}
void NativeWidgetAura::Hide() {
- window_->SetVisibility(aura::Window::VISIBILITY_HIDDEN);
}
void NativeWidgetAura::ShowMaximizedWithBounds(
const gfx::Rect& restored_bounds) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::ShowWithState(ShowState state) {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::IsVisible() const {
- return window_->visibility() != aura::Window::VISIBILITY_HIDDEN;
+ return false;
}
void NativeWidgetAura::Activate() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::Deactivate() {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::IsActive() const {
- NOTIMPLEMENTED();
return false;
}
void NativeWidgetAura::SetAlwaysOnTop(bool on_top) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::Maximize() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::Minimize() {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::IsMaximized() const {
- NOTIMPLEMENTED();
return false;
}
bool NativeWidgetAura::IsMinimized() const {
- NOTIMPLEMENTED();
return false;
}
void NativeWidgetAura::Restore() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetFullscreen(bool fullscreen) {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::IsFullscreen() const {
- NOTIMPLEMENTED();
return false;
}
void NativeWidgetAura::SetOpacity(unsigned char opacity) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetUseDragFrame(bool use_drag_frame) {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::IsAccessibleWidget() const {
- NOTIMPLEMENTED();
return false;
}
void NativeWidgetAura::RunShellDrag(View* view,
const ui::OSExchangeData& data,
int operation) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SchedulePaintInRect(const gfx::Rect& rect) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::SetCursor(gfx::NativeCursor cursor) {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::ClearNativeFocus() {
- NOTIMPLEMENTED();
}
void NativeWidgetAura::FocusNativeView(gfx::NativeView native_view) {
- NOTIMPLEMENTED();
}
bool NativeWidgetAura::ConvertPointFromAncestor(const Widget* ancestor,
gfx::Point* point) const {
- NOTIMPLEMENTED();
+ NOTREACHED();
return false;
}
void NativeWidgetAura::DispatchKeyEventPostIME(const KeyEvent& key) {
- NOTIMPLEMENTED();
}
-////////////////////////////////////////////////////////////////////////////////
-// NativeWidgetAura, aura::WindowDelegate implementation:
-
-void NativeWidgetAura::OnPaint(gfx::Canvas* canvas) {
- delegate_->OnNativeWidgetPaint(canvas);
-}
-
-////////////////////////////////////////////////////////////////////////////////
-// Widget, public:
-
-// static
-void Widget::NotifyLocaleChanged() {
- NOTIMPLEMENTED();
-}
-
-// static
-void Widget::CloseAllSecondaryWidgets() {
- NOTIMPLEMENTED();
-}
-
-bool Widget::ConvertRect(const Widget* source,
- const Widget* target,
- gfx::Rect* rect) {
- return false;
-}
-
-
-
-namespace internal {
-
-////////////////////////////////////////////////////////////////////////////////
-// internal::NativeWidgetPrivate, public:
-
-// static
-NativeWidgetPrivate* NativeWidgetPrivate::CreateNativeWidget(
- internal::NativeWidgetDelegate* delegate) {
- return new NativeWidgetAura(delegate);
-}
-
-// static
-NativeWidgetPrivate* NativeWidgetPrivate::GetNativeWidgetForNativeView(
- gfx::NativeView native_view) {
- NOTIMPLEMENTED();
- return NULL;
-}
-
-// static
-NativeWidgetPrivate* NativeWidgetPrivate::GetNativeWidgetForNativeWindow(
- gfx::NativeWindow native_window) {
- NOTIMPLEMENTED();
- return NULL;
-}
-
-// static
-NativeWidgetPrivate* NativeWidgetPrivate::GetTopLevelNativeWidget(
- gfx::NativeView native_view) {
- NOTIMPLEMENTED();
- return NULL;
-}
-
-// static
-void NativeWidgetPrivate::GetAllChildWidgets(gfx::NativeView native_view,
- Widget::Widgets* children) {
- NOTIMPLEMENTED();
-}
-
-// static
-void NativeWidgetPrivate::ReparentNativeView(gfx::NativeView native_view,
- gfx::NativeView new_parent) {
- NOTIMPLEMENTED();
-}
-
-// static
-bool NativeWidgetPrivate::IsMouseButtonDown() {
- NOTIMPLEMENTED();
- return false;
-}
-
-} // namespace internal
} // namespace views
« no previous file with comments | « views/widget/native_widget_aura.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698