Commit d5ce9f68 authored by ben@chromium.org's avatar ben@chromium.org

Stub out textfield on GTK

BUG=none
TEST=none

Review URL: http://codereview.chromium.org/115886

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17133 0039d316-1c4b-4281-b951-d872f2087c98
parent 8d3f80e9
...@@ -13,7 +13,7 @@ namespace views { ...@@ -13,7 +13,7 @@ namespace views {
static const char kViewClassName[] = "views/HWNDView"; static const char kViewClassName[] = "views/HWNDView";
HWNDView::HWNDView() { HWNDView::HWNDView() : NativeViewHost() {
} }
HWNDView::~HWNDView() { HWNDView::~HWNDView() {
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
namespace views { namespace views {
NativeControlGtk::NativeControlGtk() { NativeControlGtk::NativeControlGtk() : NativeViewHostGtk() {
} }
NativeControlGtk::~NativeControlGtk() { NativeControlGtk::~NativeControlGtk() {
......
...@@ -11,7 +11,9 @@ ...@@ -11,7 +11,9 @@
namespace views { namespace views {
NativeViewHostGtk::NativeViewHostGtk() : destroy_signal_id_(0) { NativeViewHostGtk::NativeViewHostGtk()
: NativeViewHost(),
destroy_signal_id_(0) {
} }
NativeViewHostGtk::~NativeViewHostGtk() { NativeViewHostGtk::~NativeViewHostGtk() {
......
// 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.
#include "views/controls/textfield/native_textfield_gtk.h"
namespace views {
////////////////////////////////////////////////////////////////////////////////
// NativeTextfieldGtk, public:
NativeTextfieldGtk::NativeTextfieldGtk(Textfield* textfield)
: NativeControlGtk() {
}
NativeTextfieldGtk::~NativeTextfieldGtk() {
}
////////////////////////////////////////////////////////////////////////////////
// NativeTextfieldGtk, NativeTextfieldWrapper implementation:
std::wstring NativeTextfieldGtk::GetText() const {
return std::wstring();
}
void NativeTextfieldGtk::UpdateText() {
}
void NativeTextfieldGtk::AppendText(const std::wstring& text) {
}
std::wstring NativeTextfieldGtk::GetSelectedText() const {
return std::wstring();
}
void NativeTextfieldGtk::SelectAll() {
}
void NativeTextfieldGtk::ClearSelection() {
}
void NativeTextfieldGtk::UpdateBorder() {
}
void NativeTextfieldGtk::UpdateBackgroundColor() {
}
void NativeTextfieldGtk::UpdateReadOnly() {
}
void NativeTextfieldGtk::UpdateFont() {
}
void NativeTextfieldGtk::UpdateEnabled() {
}
void NativeTextfieldGtk::SetHorizontalMargins(int left, int right) {
}
void NativeTextfieldGtk::SetFocus() {
}
View* NativeTextfieldGtk::GetView() {
return this;
}
gfx::NativeView NativeTextfieldGtk::GetTestingHandle() const {
return native_view();
}
////////////////////////////////////////////////////////////////////////////////
// NativeTextfieldGtk, NativeControlGtk overrides:
void NativeTextfieldGtk::CreateNativeControl() {
// TODO(port): create gtk text field
}
void NativeTextfieldGtk::NativeControlCreated(GtkWidget* widget) {
NativeControlGtk::NativeControlCreated(widget);
// TODO(port): post-creation init
}
} // namespace views
// 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 VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_GTK_H_
#define VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_GTK_H_
#include "views/controls/native_control_gtk.h"
#include "views/controls/textfield/native_textfield_wrapper.h"
namespace views {
class NativeTextfieldGtk : public NativeControlGtk,
public NativeTextfieldWrapper {
public:
explicit NativeTextfieldGtk(Textfield* parent);
~NativeTextfieldGtk();
// Overridden from NativeTextfieldWrapper:
virtual std::wstring GetText() const;
virtual void UpdateText();
virtual void AppendText(const std::wstring& text);
virtual std::wstring GetSelectedText() const;
virtual void SelectAll();
virtual void ClearSelection();
virtual void UpdateBorder();
virtual void UpdateBackgroundColor();
virtual void UpdateReadOnly();
virtual void UpdateFont();
virtual void UpdateEnabled();
virtual void SetHorizontalMargins(int left, int right);
virtual void SetFocus();
virtual View* GetView();
virtual gfx::NativeView GetTestingHandle() const;
// Overridden from NativeControlGtk:
virtual void CreateNativeControl();
virtual void NativeControlCreated(GtkWidget* widget);
private:
DISALLOW_COPY_AND_ASSIGN(NativeTextfieldGtk);
};
} // namespace views
#endif // VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_GTK_H_
\ No newline at end of file
...@@ -199,6 +199,6 @@ class NativeTextfieldWin ...@@ -199,6 +199,6 @@ class NativeTextfieldWin
DISALLOW_COPY_AND_ASSIGN(NativeTextfieldWin); DISALLOW_COPY_AND_ASSIGN(NativeTextfieldWin);
}; };
}; } // namespace views
#endif // VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_WIN_H_ #endif // VIEWS_CONTROLS_TEXTFIELD_NATIVE_TEXTFIELD_WIN_H_
...@@ -252,8 +252,6 @@ ...@@ -252,8 +252,6 @@
'controls/tabbed_pane.cc', 'controls/tabbed_pane.cc',
'controls/table/table_view.cc', 'controls/table/table_view.cc',
'controls/table/group_table_view.cc', 'controls/table/group_table_view.cc',
'controls/textfield/textfield.cc',
'controls/text_field.cc',
'controls/tree/tree_view.cc', 'controls/tree/tree_view.cc',
'event_win.cc', 'event_win.cc',
'resize_corner.cc', 'resize_corner.cc',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment