1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef ATHENA_HOME_PUBLIC_HOME_CARD_H_
6 #define ATHENA_HOME_PUBLIC_HOME_CARD_H_
8 #include "athena/athena_export.h"
9 #include "base/memory/scoped_ptr.h"
16 class AppModelBuilder
;
17 class SearchControllerFactory
;
19 class ATHENA_EXPORT HomeCard
{
22 // HomeCard is not visible.
25 // HomeCard is visible in the center of the screen as a normal mode.
28 // HomeCard is visible smaller at the bottom of the screen as a supplemental
32 // HomeCard is minimized (i.e. a small UI element is displayed on screen
33 // that the user can interact with to bring up the BOTTOM or CENTERED view).
37 // Creates/deletes/gets the singleton object of the HomeCard
38 // implementation. Takes the ownership of |model_builder|.
39 static HomeCard
* Create(scoped_ptr
<AppModelBuilder
> model_builder
,
40 scoped_ptr
<SearchControllerFactory
> search_factory
);
41 static void Shutdown();
42 static HomeCard
* Get();
44 virtual ~HomeCard() {}
46 // Updates/gets the current state of the home card.
47 virtual void SetState(State state
) = 0;
48 virtual State
GetState() = 0;
50 // Called when the virtual keyboard changed has changed to |bounds|. An empty
51 // |bounds| indicates that the virtual keyboard is not visible anymore.
52 virtual void UpdateVirtualKeyboardBounds(
53 const gfx::Rect
& bounds
) = 0;
58 #endif // ATHENA_HOME_PUBLIC_HOME_CARD_H_