2 * Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
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.
17 #ifndef __MUSIC_BASE_VIEW_H__
18 #define __MUSIC_BASE_VIEW_H__
31 class CMusicBaseView :
33 public IMouseMoveListener,
34 public IMouseClickedListener,
35 public IMusicControllerListener {
37 struct SMusicBaseView* m;
40 static void sm_CbHandleEmptyStatus(void *cookie, bool emptyStatus);
41 void m_OnHandleEmptyStatus(bool emptyStatus);
43 static void sm_CbCtxPopupBtnSelected(void* cookie, CCtxPopup* instance, const char* text);
44 void m_CbCtxPopupBtnSelected(CCtxPopup* instance, const char* text);
46 static Eina_Bool sm_CbShowLayoutIdler(void *cookie);
47 void m_OnShowLayoutIdler(void);
50 void m_UpdateFocusSequence(void);
51 void m_UpdateEmptyFocusSequence(void);
53 void m_ShowCurrentLayout(void);
54 void m_GotoPlayback(void);
56 void m_CreateCtxPopup(int btnType);
57 void m_DestroyCtxPopup(void);
59 Evas_Object *m_CreateLoadingPopup(void);
60 void m_DestroyPopup(void);
62 void m_UpdatePlaysongLabel(void);
63 void m_AddPlaysongLabel(void);
64 void m_CreateTopSection(void);
65 void m_CreateLeftSection(void);
66 void m_CreateFullView(void);
68 void m_SetSourceType(void);
69 void m_UpdateCurrentLayout(bool focusFlag);
71 char *m_Argument(void *data);
74 virtual void t_OnShow(void);
75 virtual void t_OnHide(void);
76 virtual void t_OnUpdate(void* data);
79 CMusicBaseView(const char *pViewId) :
81 IMouseMoveListener(this),
82 IMouseClickedListener(this),
84 virtual ~CMusicBaseView() {}
86 virtual bool Create(void *data);
87 virtual void Destroy(void);
89 virtual Evas_Object* Base(void);
92 virtual void OnKeyDown(int id, Evas *e, Evas_Object *obj, Evas_Event_Key_Down *ev);
93 virtual void OnKeyUp(int id, Evas *e, Evas_Object *obj, Evas_Event_Key_Up *ev);
94 virtual void OnMouseMove(int id, Evas *e, Evas_Object *obj, Evas_Event_Mouse_Move *ev);
95 virtual void OnMouseClicked(int id, Evas_Object *obj);
97 virtual void OnComplete(void);
98 virtual void OnError(void);
99 virtual void OnUsbStatusChanged(SUsbStorageStatus status);
100 virtual void OnUpdateContent(void);
104 #endif /*__MUSIC_BASE_VIEW_H__*/