| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include "views/controls/textfield/textfield.h" | 5 #include "views/controls/textfield/textfield.h" |
| 6 | 6 |
| 7 #if defined(OS_LINUX) | 7 #if defined(OS_LINUX) |
| 8 #include <gdk/gdkkeysyms.h> | 8 #include <gdk/gdkkeysyms.h> |
| 9 #endif | 9 #endif |
| 10 | 10 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 default_width_in_chars_(0), | 48 default_width_in_chars_(0), |
| 49 draw_border_(true), | 49 draw_border_(true), |
| 50 text_color_(SK_ColorBLACK), | 50 text_color_(SK_ColorBLACK), |
| 51 use_default_text_color_(true), | 51 use_default_text_color_(true), |
| 52 background_color_(SK_ColorWHITE), | 52 background_color_(SK_ColorWHITE), |
| 53 use_default_background_color_(true), | 53 use_default_background_color_(true), |
| 54 num_lines_(1), | 54 num_lines_(1), |
| 55 initialized_(false), | 55 initialized_(false), |
| 56 horizontal_margins_were_set_(false), | 56 horizontal_margins_were_set_(false), |
| 57 vertical_margins_were_set_(false) { | 57 vertical_margins_were_set_(false) { |
| 58 SetFocusable(true); | 58 set_focusable(true); |
| 59 } | 59 } |
| 60 | 60 |
| 61 Textfield::Textfield(StyleFlags style) | 61 Textfield::Textfield(StyleFlags style) |
| 62 : native_wrapper_(NULL), | 62 : native_wrapper_(NULL), |
| 63 controller_(NULL), | 63 controller_(NULL), |
| 64 style_(style), | 64 style_(style), |
| 65 read_only_(false), | 65 read_only_(false), |
| 66 default_width_in_chars_(0), | 66 default_width_in_chars_(0), |
| 67 draw_border_(true), | 67 draw_border_(true), |
| 68 text_color_(SK_ColorBLACK), | 68 text_color_(SK_ColorBLACK), |
| 69 use_default_text_color_(true), | 69 use_default_text_color_(true), |
| 70 background_color_(SK_ColorWHITE), | 70 background_color_(SK_ColorWHITE), |
| 71 use_default_background_color_(true), | 71 use_default_background_color_(true), |
| 72 num_lines_(1), | 72 num_lines_(1), |
| 73 initialized_(false), | 73 initialized_(false), |
| 74 horizontal_margins_were_set_(false), | 74 horizontal_margins_were_set_(false), |
| 75 vertical_margins_were_set_(false) { | 75 vertical_margins_were_set_(false) { |
| 76 SetFocusable(true); | 76 set_focusable(true); |
| 77 } | 77 } |
| 78 | 78 |
| 79 Textfield::~Textfield() { | 79 Textfield::~Textfield() { |
| 80 } | 80 } |
| 81 | 81 |
| 82 void Textfield::SetController(TextfieldController* controller) { | 82 void Textfield::SetController(TextfieldController* controller) { |
| 83 controller_ = controller; | 83 controller_ = controller; |
| 84 } | 84 } |
| 85 | 85 |
| 86 TextfieldController* Textfield::GetController() const { | 86 TextfieldController* Textfield::GetController() const { |
| (...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 } | 407 } |
| 408 #endif | 408 #endif |
| 409 } | 409 } |
| 410 } | 410 } |
| 411 | 411 |
| 412 std::string Textfield::GetClassName() const { | 412 std::string Textfield::GetClassName() const { |
| 413 return kViewClassName; | 413 return kViewClassName; |
| 414 } | 414 } |
| 415 | 415 |
| 416 } // namespace views | 416 } // namespace views |
| OLD | NEW |