{
class ISystemSettingsManager;
+ /**
+ * @brief Monitors changing of time format and system language. Also reads telephony settings.
+ */
class SystemSettingsManager
{
public:
+ /**
+ * @brief A constructor initializes telephony handle to make system settings manager instance to read telephony settings.
+ */
SystemSettingsManager();
~SystemSettingsManager();
+ /**
+ * @brief Adds a subscriber on system settings change events.
+ * @param[in] l a listener.
+ */
void addListener(ISystemSettingsManager &l);
+
+ /**
+ * @brief Removes system settings changes listener.
+ * @param[in] l a listener to be removed.
+ */
void removeListener(ISystemSettingsManager&l);
+
+ /**
+ * @brief Checks whether SIM is inserted or not.
+ * @return true if SIM is inserted, false otherwise.
+ */
bool isSimInserted() const;
+
+ /**
+ * @brief Checks whether network service is available or not.
+ * @return true if network service available, false otherwise(service is unavailable or only emergency calls are available).
+ */
bool isSimActive() const;
+
+ /**
+ * @brief Checks whether mobile data is enabled or not.
+ * @return true if 3g mobile data is enabled, false otherwise.
+ */
bool isMobileDataEnabled() const;
private:
telephony_handle_list_s m_TelHandleList;
};
+ /**
+ * @brief A listener-interface that should be implemented by subscriber in order to be notified about time format or nsystem language change.
+ */
class ISystemSettingsManager
{
public:
virtual ~ISystemSettingsManager() {}
+ /**
+ * @brief Notification about change of time format.
+ */
virtual void onTimeFormatChanged() {};
+
+ /**
+ * @brief Notification about change of system language.
+ */
virtual void onLanguageChanged() {};
};
}
namespace Msg
{
+ /**
+ * @brief Wraps all basic Box operations.
+ */
class Box
: public View
{
Box(Evas_Object *parent);
virtual ~Box();
+ /**
+ * @brief Set the horizontal orientation of box.
+ * @param[in] val if true box's orientation becomes horizontal otherwise it becomes vertical.
+ */
inline void setHorizontal(bool val);
+
+ /**
+ * @brief Manages homogeneous mode of box.
+ * @param[in] val if true homogeneous mode is on, otherwise it's off.
+ */
inline void setHomogeneous(bool val);
+
+ /**
+ * @brief Add an object to the beginning of the pack list.
+ * @param[in] obj an object to be added.
+ */
inline void packStart(Evas_Object *obj);
+
+ /**
+ * @brief Add an object at the end of the pack list.
+ * @param[in] obj an object to be added.
+ */
inline void packEnd(Evas_Object *obj);
+
+ /**
+ * @brief Adds an object to the box before the indicated object.
+ * @param[in] subobj an object to be added.
+ * @param[in] before the object before which to add it.
+ */
inline void packBefore(Evas_Object *subobj, Evas_Object *before);
+
+ /**
+ * @brief Adds an object to the box after the indicated object.
+ * @param[in] subobj an object to be added.
+ * @param[in] after the object after which to add it.
+ */
inline void packAfter(Evas_Object *subobj, Evas_Object *after);
+
+ /**
+ * @brief Remove the object given by @c subobj from the box without deleting it.
+ * @param[in] subobj an object to be removed.
+ */
inline void unpack(Evas_Object *subobj);
+
+ /**
+ * @brief Remove all items from the box, without deleting them.
+ */
inline void unpackAll();
+
+ /**
+ * @brief Clear the box of all children, children will be deleted.
+ */
inline void clear();
+
+ /**
+ * @brief Force the box to recalculate its children packing.
+ */
inline void recalculate();
};
{
class MbeRecipientsView;
+ /**
+ * @brief Wraps all basic multibutton entry item operations.
+ */
class MbeRecipientItem
: public ViewItem
{
friend class MbeRecipientsView;
public:
+ /**
+ * @brief Constructs instance of MbeRecipientItem with a specified display-name, address etc.
+ * @param[in] address recipient-address(phone number or email).
+ * @param[in] dispName displayable mbe-item text.
+ * @param[in] addressType type of recipient address.
+ * @param[in] recipType type of recipient.
+ */
MbeRecipientItem(const std::string &address, const std::string &dispName,
MsgAddress::AddressType addressType, MsgAddress::RecipientType recipType = MsgAddress::To);
+ /**
+ * @brief Gets recipient's display-name.
+ * @return display-name.
+ */
const std::string &getDispName() const;
+
+ /**
+ * @brief Gets recipient address.
+ * @return recipient address.
+ */
const std::string &getAddress() const;
+
+ /**
+ * @brief Gets address-type.
+ * @return address-type.
+ */
MsgAddress::AddressType getAddressType() const;
+
+ /**
+ * @brief Gets recipient type.
+ * @return recipient type.
+ */
MsgAddress::RecipientType getRecipType() const;
+ /**
+ * @brief Sets new display name.
+ * @param[in] dispName new display name.
+ */
void setDispName(const std::string &dispName);
private:
{
class IMbeRecipientsListener;
+ /**
+ * @brief Wraps all basic multibutton entry(mbe) operations.
+ */
class MbeRecipientsView
: public View
{
MbeRecipientsView(Evas_Object *parent);
virtual ~MbeRecipientsView();
+ /**
+ * @brief Appends new item into mbe.
+ * @param[in] item new item to be appended.
+ */
void appendItem(MbeRecipientItem &item);
+
+ /**
+ * @brief Gets number of mbe items.
+ * @return items count.
+ */
int getItemsCount() const;
+
+ /**
+ * @brief Gets mbe items collection.
+ * @return mbe items.
+ */
std::vector<MbeRecipientItem*> getItems() const;
+
+ /**
+ * @brief Gets mbe's selected item.
+ * @return selected item or nullptr if no item is selected.
+ */
MbeRecipientItem *getSelectedItem() const;
+
+ /**
+ * @brief Checks whether mbe is empty or not.
+ * @return true if mbe is empty false otherwise.
+ */
bool isEmpty() const;
+
+ /**
+ * @brief Removes all mbe items.
+ */
void clear();
+
void setListener(IMbeRecipientsListener *pListener);
private:
void onMbeItemClicked(Evas_Object *obj, void *eventInfo);
Ecore_Job *m_pChangedJob;
};
+ /**
+ * @brief A listener class that should be implemented by all mbe event subscribers.
+ */
class IMbeRecipientsListener
{
public:
virtual ~IMbeRecipientsListener() {};
+
+ /**
+ * @brief Notification about some mbe item being clicked.
+ * @param[in] item clicked item.
+ */
virtual void onMbeItemClicked(MbeRecipientItem &item) {};
- virtual void onMbeChanged() {}; // Added/Deleted
+
+ /**
+ * @brief Notification about mbe content being changed(Item was added or deleted).
+ */
+ virtual void onMbeChanged() {};
};
}
class NaviFrameItem;
typedef std::vector<NaviFrameItem*> NaviFrameItemList;
+ /**
+ * @brief Wraps all basic Naviframe-item operations.
+ */
class NaviFrameItem
: public ViewItem
{
friend class NaviFrameView;
public:
+ /**
+ * @brief An identifiers of buttons that can be shown on the top naviframe-item.
+ */
enum NaviButtonId
{
- NaviCancelButtonId = 0,
- NaviOkButtonId,
- NaviCenterButtonId,
- NaviPrevButtonId,
- NaviExpandButtonId,
+ NaviCancelButtonId = 0,/**< Cancel-button */
+ NaviOkButtonId, /**< OK-button */
+ NaviCenterButtonId, /**< Central-button */
+ NaviPrevButtonId, /**< "Previous"-button */
+ NaviExpandButtonId, /**< "Expand"-button */
NaviButtonMax
};
public:
class NaviBar;
+ /**
+ * A constructor of NaviFrameItem object based on outside parent object. Creates nested navibar.
+ * @param[in] owner an object responsible for automatic removing of NaviFrameItem instance.
+ */
NaviFrameItem(NaviFrameView &owner);
virtual ~NaviFrameItem();
public:
+ /**
+ * @brief Gets nested navibar.
+ * @return nested navibar.
+ */
const NaviBar &getNaviBar() const;
NaviBar &getNaviBar();
+
+ /**
+ * @brief Gets NaviframeView that owns this item.
+ * @return owner of this item.
+ */
NaviFrameView &getOwner();
const NaviFrameView &getOwner() const;
NaviBar *m_pNaviBar;
};
+ /**
+ * @brief A bar at the top of NaviFrameItem.
+ */
class NaviFrameItem::NaviBar
: public View
{
friend class NaviFrameItem;
public:
+ /**
+ * @brief An enumeration of colors that could be applied to Navibar's background.
+ */
enum NaviColorId
{
- NaviBlueColorId = 0,
- NaviWhiteColorId,
+ NaviBlueColorId = 0,/**< Blue */
+ NaviWhiteColorId, /**< White */
NaviColorMax
};
public:
+ /**
+ * @brief Gets NaviframeItem instance that owns this navibar
+ * @return owner of this navibar.
+ */
NaviFrameItem &getOwner();
const NaviFrameItem &getOwner() const;
+
+ /**
+ * @brief Manages navibar's visibility.
+ * @param[in] visible if true shows navibar, if false - hides it.
+ */
void setVisible(bool visible);
+
+ /**
+ * @brief Sets navibar title with a specified plain text.
+ * @param[in] title a plain text of new title.
+ */
void setTitle(const std::string &title);
+
+ /**
+ * @brief Sets Title with translatable string-id.
+ * @param[in] title translatable text.
+ */
void setTitle(const TText &title);
+
+ /**
+ * @brief Gets navibar title text.
+ * @return title.
+ */
std::string getTitle() const;
+
+ /**
+ * @brief Manages visibility of navibar-button identified with specified id.
+ * @param[in] id button-id.
+ * @param[in] value if true the button is visible, if false - hides the button.
+ */
void showButton(NaviButtonId id, bool value);
+
+ /**
+ * @brief Disables(enables) button with specified id.
+ * @param[in] id id of button to be disabled(enabled).
+ * @param[in] value if true disables the button otherwise enables it.
+ */
void disabledButton(NaviButtonId id, bool value);
+
+ /**
+ * @brief Sets specified plain text to a button with specified id.
+ * @param[in] id button-id.
+ * @param[in] text a plain text to set.
+ */
void setButtonText(NaviButtonId id, const std::string &text);
+
+ /**
+ * @brief Sets specified translatable text to a button with specified id.
+ * @param[in] id button-id.
+ * @param[in] text a translatable text to set.
+ */
void setButtonText(NaviButtonId id, const TText &text);
+
+ /**
+ * @brief Hides all buttons on navibar.
+ */
void clear();
+
+ /**
+ * @brief Sets search-panel layout.
+ * @param[in] searchPanel a layout with search panel.
+ */
void setSearch(Evas_Object *searchPanel);
+
+ /**
+ * @brief Gets search-panel layout.
+ * @return layout with search panel.
+ */
Evas_Object *getSearch();
const Evas_Object *getSearch() const;
+
+ /**
+ * @brief Shows search-panel.
+ */
void showSearch();
+
+ /**
+ * @brief Hides search-panel.
+ */
void hideSearch();
+
+ /**
+ * @brief Changes navibar color.
+ * @param[in] id code of supported color.
+ */
void setColor(NaviColorId id);
+
+ /**
+ * @brief Manages state of down-button.
+ * @param Changes picture of down-button. If true sets down-arrow to down-button otherwise sets up-arrow there.
+ */
void setDownButtonState(bool expand);
private:
namespace Msg
{
+ /**
+ * @brief Wraps all basic Naviframe operations.
+ */
class NaviFrameView
: public View
{
*/
void push(NaviFrameItem &item, Evas_Object *content = nullptr);
void push(NaviFrameItem &item, View &content);
+
+ /**
+ * @brief Pops item from Naviframe.
+ */
void pop();
+
+ /**
+ * @brief Inserts specified item to bottom of item's stack.
+ * @param[in] item an item to be inserted.
+ */
void insertToBottom(NaviFrameItem &item);
+
+ /**
+ * @brief Promote an item already in the naviframe stack to the top of the stack
+ * @param[in] item an item to be promoted.
+ */
void promote(NaviFrameItem &item);
+
+ /**
+ * @brief Gets top frame from items-stack.
+ * @return Top naviframe-item or nullptr if item-stack is empty.
+ */
NaviFrameItem *getTopFrame() const;
+
+ /**
+ * Checks if item transition is in progress.
+ * @return true if transition is in progress, false otherwise.
+ */
bool getTransitionStatus() const;
private:
namespace Msg
{
+ /**
+ * @brief A popup with list of available popup items.
+ */
class PopupList
: public Popup
, private IListViewListener
PopupList(PopupManager &parent);
virtual ~PopupList();
+ /**
+ * @brief Appends specified existing item to popup list.
+ * @param[in] item an item created outside to be appended.
+ */
void appendItem(PopupListItem &item);
+
+ /**
+ * @brief Creates an item with a single string based on specified parameters and appends it to popup list.
+ * @param[in] text a text displayed on popup list item.
+ * @param[in] cb a callback raised by tap on this item.
+ * @param[in] userData user data passed to item's on-press callback.
+ */
void appendItem(const std::string &text, PopupListItemPressedCb cb, void *userData);
+
+ /**
+ * Creates an item with a single string and a stored filepath based on specified parameters and appends it to popup list.
+ * @param[in] text a text displayed on popup list item.
+ * @param[in] path filepath.
+ * @param[in] cb a callback raised by tap on this item.
+ * @param[in] userData user data passed to item's on-press callback.
+ */
void appendItem(const std::string &text, const std::string &path, PopupListItemPressedCb cb, void *userData);
+
+ /**
+ * @brief Gets nested list-view.
+ * @return list-view.
+ */
ListView &getListView();
const ListView &getListView() const;
{
class PopupList;
class PopupListItem;
+
+ /** @brief Callback raised when popup-list item was clicked.*/
typedef void (*PopupListItemPressedCb)(PopupListItem &item, void *userData);
#define POPUPLIST_ITEM_PRESSED_CB(ClassName, method) [](PopupListItem &item, void *userData) \
{ \
};
/**
- * @brief A class of popup-item with single text displayed
+ * @brief A class of popup-item with single text displayed.
*/
class PopupTextListItem: public PopupListItem
{
};
/**
- * @brief A class of popup-item with text and check field
+ * @brief A class of popup-item with text and check field.
*/
class PopupCheckListItem: public PopupListItem
{
{
class Window;
+ /**
+ * @brief A global instance that manages context popups and regular popups lifecycle in context of one window.
+ */
class PopupManager
{
public:
+ /**
+ * @brief Creating PopupManager instance in context of specified window.
+ * @param[in] window a window context.
+ */
PopupManager(Window &window);
~PopupManager();
PopupManager(PopupManager&) = delete;
PopupManager &operator=(PopupManager&) = delete;
+ /**
+ * @brief Gets window-context.
+ * @return window-context.
+ */
Window &getWindow() const;
+
+ /**
+ * @brief Checks whether any context or regular popup is visible.
+ * @return false if no popup is visible otherwise true.
+ */
bool isVisible() const;
+
+ /**
+ * @brief Destroys all popups (context and regular) created before.
+ * If no popup was created nothing happens.
+ */
void reset();
+
+ /**
+ * @brief Destroys specified popup.
+ * @param[in] popup a popup to be destroyed.
+ */
void reset(Popup &popup);
+ /**
+ * @brief Creates popup-list.
+ * @return created popup-list.
+ */
PopupList &getPopupList();
+
+ /**
+ * @brief Creates popup.
+ * @return popup created.
+ */
Popup &getPopup();
+
+ /**
+ * @brief Checks whether popup exists and it's visible.
+ * @return true if popup exists and it's visible, false otherwise.
+ */
bool isPopupVisible() const;
+
+ /**
+ * @brief Destroys popup. If no popup exists nothing happens.
+ */
void resetPopup();
+ /**
+ * @brief Creates context popup.
+ * @return context popup created.
+ */
ContextPopup &getCtxPopup();
+
+ /**
+ * @brief Checks whether context popup exists and it's visible.
+ * @return true if context popup exists and it's visible, false otherwise.
+ */
bool isCtxPopupVisible() const;
+
+ /**
+ * @brief Destroys context popup. If no context popup exists nothing happens.
+ */
void resetCtxPopup();
private:
virtual ~View();
/**
- * @brief Allows children-classes to perform some cleanup activities before they destroying.
+ * @brief Allows children-classes to perform some cleanup activities before their destroying.
* @param[in] view to be destroyed after exiting onBeforeDelete().
*/
virtual void onBeforeDelete(View &view) {};
namespace Msg
{
+ /**
+ * @brief An interface that should be implemented by all window-classes across whole application.
+ */
class Window
: public View
{