2 * Copyright (c) 2015 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
20 #include <dali-toolkit/public-api/focus-manager/keyboard-focus-manager.h>
23 #include <cstring> // for strcmp
27 #include <dali-toolkit/internal/focus-manager/keyboard-focus-manager-impl.h>
35 KeyboardFocusManager::KeyboardFocusManager()
39 KeyboardFocusManager::~KeyboardFocusManager()
43 KeyboardFocusManager KeyboardFocusManager::Get()
45 return Internal::KeyboardFocusManager::Get();
48 KeyboardFocusManager::KeyboardFocusManager(Internal::KeyboardFocusManager *impl)
53 bool KeyboardFocusManager::SetCurrentFocusActor(Actor actor)
55 return GetImpl(*this).SetCurrentFocusActor(actor);
58 Actor KeyboardFocusManager::GetCurrentFocusActor()
60 return GetImpl(*this).GetCurrentFocusActor();
63 bool KeyboardFocusManager::MoveFocus(Control::KeyboardFocus::Direction direction)
65 return GetImpl(*this).MoveFocus(direction);
68 void KeyboardFocusManager::ClearFocus()
70 GetImpl(*this).ClearFocus();
73 void KeyboardFocusManager::SetAsFocusGroup(Actor actor, bool isFocusGroup)
76 GetImpl(*this).SetAsFocusGroup(actor, isFocusGroup);
79 bool KeyboardFocusManager::IsFocusGroup(Actor actor) const
82 return GetImpl(*this).IsFocusGroup(actor);
85 Actor KeyboardFocusManager::GetFocusGroup(Actor actor)
87 return GetImpl(*this).GetFocusGroup(actor);
90 void KeyboardFocusManager::SetFocusGroupLoop(bool enabled)
92 GetImpl(*this).SetFocusGroupLoop(enabled);
95 bool KeyboardFocusManager::GetFocusGroupLoop() const
97 return GetImpl(*this).GetFocusGroupLoop();
100 void KeyboardFocusManager::SetFocusIndicatorActor(Actor indicator)
102 GetImpl(*this).SetFocusIndicatorActor(indicator);
105 Actor KeyboardFocusManager::GetFocusIndicatorActor()
107 return GetImpl(*this).GetFocusIndicatorActor();
110 KeyboardFocusManager::PreFocusChangeSignalType& KeyboardFocusManager::PreFocusChangeSignal()
112 return GetImpl(*this).PreFocusChangeSignal();
115 KeyboardFocusManager::FocusChangedSignalType& KeyboardFocusManager::FocusChangedSignal()
117 return GetImpl(*this).FocusChangedSignal();
120 KeyboardFocusManager::FocusGroupChangedSignalType& KeyboardFocusManager::FocusGroupChangedSignal()
122 return GetImpl(*this).FocusGroupChangedSignal();
125 KeyboardFocusManager::FocusedActorEnterKeySignalType& KeyboardFocusManager::FocusedActorEnterKeySignal()
127 return GetImpl(*this).FocusedActorEnterKeySignal();
130 } // namespace Toolkit