Chromium Code Reviews| Index: ash/magnifier/partial_magnification_controller.h |
| diff --git a/ash/magnifier/partial_magnification_controller.h b/ash/magnifier/partial_magnification_controller.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..fe4e5a3f7fa72af6d3c5cc87160c37974b04aa9e |
| --- /dev/null |
| +++ b/ash/magnifier/partial_magnification_controller.h |
| @@ -0,0 +1,51 @@ |
| +// Copyright (c) 2012 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 ASH_MAGNIFIER_PARTIAL_MAGNIFICATION_CONTROLLER_H_ |
| +#define ASH_MAGNIFIER_PARTIAL_MAGNIFICATION_CONTROLLER_H_ |
| + |
| +#include "base/compiler_specific.h" |
| +#include "base/logging.h" |
| +#include "base/memory/scoped_ptr.h" |
| +#include "ui/aura/event_filter.h" |
| +#include "ui/gfx/point.h" |
| +#include "ui/gfx/rect.h" |
|
oshima
2012/09/07 22:30:55
clean up unused headers
Zachary Kuznia
2012/09/13 11:49:02
Done.
|
| + |
| +namespace aura { |
| +class RootWindow; |
| +} |
| + |
| +namespace ash { |
| +namespace internal { |
| + |
| +const float kDefaultPartialMagnifiedScale = 1.5f; |
| +const float kNonPartialMagnifiedScale = 1.0f; |
| + |
| +class PartialMagnificationController { |
|
sky
2012/09/07 16:06:59
Description.
Zachary Kuznia
2012/09/13 11:49:02
Done.
|
| + public: |
| + virtual ~PartialMagnificationController() {} |
| + |
| + // Creates a new PartialMagnificationController. The caller takes ownership |
| + // of the returned object. |
| + static PartialMagnificationController* CreateInstance(); |
| + |
| + // Enables (or disables if |enabled| is false) partial screen magnifier |
| + // feature. |
| + virtual void SetEnabled(bool enabled) = 0; |
| + |
| + virtual bool IsEnabled() = 0; |
| + |
| + // Sets the magnification ratio. 1.0f means no magnification. |
| + virtual void SetScale(float scale) = 0; |
| + // Returns the current magnification ratio. |
| + virtual float GetScale() const = 0; |
| + |
| + protected: |
| + PartialMagnificationController() {} |
| +}; |
| + |
| +} // namespace internal |
| +} // namespace ash |
| + |
| +#endif // ASH_MAGNIFIER_PARTIAL_MAGNIFICATION_CONTROLLER_H_ |