Back to index

unity  6.0.0
Public Types | Public Member Functions | Public Attributes | Protected Member Functions | Private Member Functions
unity::launcher::AbstractLauncherIcon Class Reference

#include <AbstractLauncherIcon.h>

Inheritance diagram for unity::launcher::AbstractLauncherIcon:
Inheritance graph
[legend]
Collaboration diagram for unity::launcher::AbstractLauncherIcon:
Collaboration graph
[legend]

List of all members.

Public Types

enum  IconType {
  TYPE_NONE, TYPE_BEGIN, TYPE_HOME, TYPE_HUD,
  TYPE_FAVORITE, TYPE_APPLICATION, TYPE_EXPO, TYPE_DESKTOP,
  TYPE_PLACE, TYPE_DEVICE, TYPE_TRASH, TYPE_END
}
enum  Quirk {
  QUIRK_VISIBLE, QUIRK_ACTIVE, QUIRK_RUNNING, QUIRK_URGENT,
  QUIRK_PRESENTED, QUIRK_STARTING, QUIRK_SHIMMER, QUIRK_CENTER_SAVED,
  QUIRK_PROGRESS, QUIRK_DROP_PRELIGHT, QUIRK_DROP_DIM, QUIRK_DESAT,
  QUIRK_PULSE_ONCE, QUIRK_LAST_ACTION, QUIRK_LAST
}
typedef nux::ObjectPtr
< AbstractLauncherIcon
Ptr
typedef std::vector< nux::Vector4 > TransformVector
enum  TransformIndex {
  TRANSFORM_TILE, TRANSFORM_IMAGE, TRANSFORM_HIT_AREA, TRANSFORM_GLOW,
  TRANSFORM_EMBLEM
}
typedef std::list
< Introspectable * > 
IntrospectableList

Public Member Functions

virtual ~AbstractLauncherIcon ()
virtual void HideTooltip ()=0
virtual void SetShortcut (guint64 shortcut)=0
virtual guint64 GetShortcut ()=0
virtual void SetSortPriority (int priority)=0
virtual bool OpenQuicklist (bool select_first_item=false, int monitor=-1)=0
virtual void SetCenter (nux::Point3 center, int monitor, nux::Geometry parent_geo)=0
virtual nux::Point3 GetCenter (int monitor)=0
virtual nux::Point3 GetSavedCenter (int monitor)=0
virtual void SaveCenter ()=0
virtual void Activate (ActionArg arg)=0
virtual void OpenInstance (ActionArg arg)=0
virtual int SortPriority ()=0
virtual std::vector< Window > Windows ()=0
virtual std::vector< Window > WindowsForMonitor (int monitor)=0
virtual std::vector< Window > WindowsOnViewport ()=0
virtual std::string NameForWindow (Window window)=0
virtual const bool WindowVisibleOnMonitor (int monitor)=0
virtual const bool WindowVisibleOnViewport ()=0
virtual bool IsSpacer ()=0
virtual float PresentUrgency ()=0
virtual float GetProgress ()=0
virtual bool ShowInSwitcher (bool current)=0
virtual unsigned long long SwitcherPriority ()=0
virtual bool GetQuirk (Quirk quirk) const =0
virtual void SetQuirk (Quirk quirk, bool value)=0
virtual struct timespec GetQuirkTime (Quirk quirk)=0
virtual void ResetQuirkTime (Quirk quirk)=0
virtual IconType GetIconType ()=0
virtual std::string RemoteUri ()=0
virtual std::list
< DbusmenuMenuitem * > 
Menus ()=0
virtual nux::DndAction QueryAcceptDrop (DndData const &dnd_data)=0
virtual bool ShouldHighlightOnDrag (DndData const &dnd_data)=0
virtual void AcceptDrop (DndData const &dnd_data)=0
virtual void SendDndEnter ()=0
virtual void SendDndLeave ()=0
virtual void InsertEntryRemote (LauncherEntryRemote::Ptr const &remote)=0
virtual void RemoveEntryRemote (LauncherEntryRemote::Ptr const &remote)=0
virtual std::string DesktopFile ()=0
virtual bool IsSticky () const =0
virtual bool IsVisible () const =0
virtual bool IsVisibleOnMonitor (int monitor) const =0
virtual void SetVisibleOnMonitor (int monitor, bool visible)=0
virtual void AboutToRemove ()=0
virtual void Stick (bool save=true)=0
virtual void UnStick ()=0
std::vector< nux::Vector4 > & GetTransform (TransformIndex index, int monitor)
virtual nux::Color BackgroundColor () const =0
virtual nux::Color GlowColor ()=0
virtual nux::BaseTexture * TextureForSize (int size)=0
virtual nux::BaseTexture * Emblem ()=0
GVariant * Introspect ()
virtual std::string GetName () const =0
void AddChild (Introspectable *child)
void RemoveChild (Introspectable *child)
virtual void AddProperties (GVariantBuilder *builder)=0
virtual IntrospectableList GetIntrospectableChildren ()
guint64 GetIntrospectionId () const

Public Attributes

nux::Property< std::string > tooltip_text
nux::Property< bool > tooltip_enabled
sigc::signal< void, int, int,
unsigned long > 
mouse_down
sigc::signal< void, int, int,
unsigned long > 
mouse_up
sigc::signal< void, int, int,
unsigned long > 
mouse_click
sigc::signal< void, int > mouse_enter
sigc::signal< void, int > mouse_leave
sigc::signal< void,
AbstractLauncherIcon::Ptr
needs_redraw
sigc::signal< void,
AbstractLauncherIcon::Ptr
remove
sigc::signal< void,
nux::ObjectPtr< nux::View > > 
tooltip_visible
sigc::signal< void > visibility_changed
sigc::connection needs_redraw_connection
sigc::connection on_icon_added_connection
sigc::connection on_icon_removed_connection
sigc::connection on_order_changed_connection
sigc::connection on_expo_terminated_connection

Protected Member Functions

virtual std::string GetChildsName () const
 Please don't override this unless you really need to. The only valid reason is if you have a property that simply must be called 'Children'.

Private Member Functions

 NUX_DECLARE_OBJECT_TYPE (AbstractLauncherIcon, ui::IconTextureSource)

Detailed Description

Definition at line 76 of file AbstractLauncherIcon.h.


Member Typedef Documentation

Definition at line 34 of file Introspectable.h.

Reimplemented from unity::ui::IconTextureSource.

Reimplemented in unity::launcher::SoftwareCenterLauncherIcon.

Definition at line 80 of file AbstractLauncherIcon.h.

typedef std::vector<nux::Vector4> unity::launcher::AbstractLauncherIcon::TransformVector

Definition at line 81 of file AbstractLauncherIcon.h.


Member Enumeration Documentation

Enumerator:
TYPE_NONE 
TYPE_BEGIN 
TYPE_HOME 
TYPE_HUD 
TYPE_FAVORITE 
TYPE_APPLICATION 
TYPE_EXPO 
TYPE_DESKTOP 
TYPE_PLACE 
TYPE_DEVICE 
TYPE_TRASH 
TYPE_END 

Definition at line 83 of file AbstractLauncherIcon.h.

Enumerator:
QUIRK_VISIBLE 
QUIRK_ACTIVE 
QUIRK_RUNNING 
QUIRK_URGENT 
QUIRK_PRESENTED 
QUIRK_STARTING 
QUIRK_SHIMMER 
QUIRK_CENTER_SAVED 
QUIRK_PROGRESS 
QUIRK_DROP_PRELIGHT 
QUIRK_DROP_DIM 
QUIRK_DESAT 
QUIRK_PULSE_ONCE 
QUIRK_LAST_ACTION 
QUIRK_LAST 

Definition at line 99 of file AbstractLauncherIcon.h.

Enumerator:
TRANSFORM_TILE 
TRANSFORM_IMAGE 
TRANSFORM_HIT_AREA 
TRANSFORM_GLOW 
TRANSFORM_EMBLEM 

Definition at line 39 of file IconTextureSource.h.


Constructor & Destructor Documentation

Definition at line 119 of file AbstractLauncherIcon.h.

{}

Member Function Documentation

virtual void unity::launcher::AbstractLauncherIcon::AcceptDrop ( DndData const &  dnd_data) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::Activate ( ActionArg  arg) [pure virtual]

Definition at line 78 of file Introspectable.cpp.

{
  _children.push_back(child);
  child->_parents.push_back(this);
}

Here is the caller graph for this function:

virtual void unity::debug::Introspectable::AddProperties ( GVariantBuilder *  builder) [pure virtual, inherited]
virtual nux::Color unity::ui::IconTextureSource::BackgroundColor ( ) const [pure virtual, inherited]
virtual std::string unity::launcher::AbstractLauncherIcon::DesktopFile ( ) [pure virtual]
virtual nux::BaseTexture* unity::ui::IconTextureSource::Emblem ( ) [pure virtual, inherited]

Implemented in unity::launcher::MockLauncherIcon, unity::launcher::LauncherIcon, and unity::hud::HudIconTextureSource.

Here is the caller graph for this function:

virtual nux::Point3 unity::launcher::AbstractLauncherIcon::GetCenter ( int  monitor) [pure virtual]
std::string unity::debug::Introspectable::GetChildsName ( ) const [protected, virtual, inherited]

Please don't override this unless you really need to. The only valid reason is if you have a property that simply must be called 'Children'.

Definition at line 92 of file Introspectable.cpp.

{
  return "Children";
}

Here is the caller graph for this function:

Introspectable::IntrospectableList unity::debug::Introspectable::GetIntrospectableChildren ( ) [virtual, inherited]

Reimplemented in unity::hud::View, unity::launcher::LauncherModel, unity::QuicklistView, and unity::dash::ResultView.

Definition at line 41 of file Introspectable.cpp.

{
  return _children;
}

Here is the caller graph for this function:

guint64 unity::debug::Introspectable::GetIntrospectionId ( ) const [inherited]

Definition at line 97 of file Introspectable.cpp.

{
  return _id;
}

Here is the caller graph for this function:

virtual std::string unity::debug::Introspectable::GetName ( ) const [pure virtual, inherited]

Implemented in unity::WindowButton, unity::launcher::LauncherIcon, unity::UnityScreen, WindowManager, unity::launcher::Launcher, unity::dash::DashView, unity::dash::LensView, unity::switcher::Controller, unity::SearchBar, unity::launcher::BamfLauncherIcon, unity::QuicklistMenuItem, unity::PanelIndicatorEntryView, unity::launcher::LauncherModel, unity::switcher::SwitcherModel, unity::PlacesGroup, unity::hud::View, unity::launcher::Controller, unity::dash::FilterExpanderLabel, unity::PanelIndicatorsView, unity::dash::LensBar, unity::QuicklistView, unity::switcher::SwitcherView, unity::PanelView, unity::LauncherEntryRemote, unity::hud::Controller, unity::IconTexture, unity::hud::HudButton, unity::PanelMenuView, unity::WindowButtons, unity::dash::Controller, unity::dash::ResultView, unity::shortcut::View, unity::shortcut::Controller, unity::dash::FilterBar, unity::ui::UnityWindowView, unity::launcher::MockLauncherIcon, unity::panel::Controller, unity::PanelTitlebarGrabArea, unity::SearchBarSpinner, unity::dash::LensBarIcon, unity::PanelTray, unity::Tooltip, unity::launcher::BFBLauncherIcon, unity::launcher::DesktopLauncherIcon, unity::launcher::SimpleLauncherIcon, unity::launcher::TrashLauncherIcon, unity::launcher::HudLauncherIcon, unity::launcher::DeviceLauncherIcon, unity::launcher::SoftwareCenterLauncherIcon, unity::hud::Icon, unity::launcher::SingleMonitorLauncherIcon, unity::launcher::SpacerLauncherIcon, unity::debug::ResultWrapper, and MockIntrospectable.

Here is the caller graph for this function:

virtual float unity::launcher::AbstractLauncherIcon::GetProgress ( ) [pure virtual]
virtual bool unity::launcher::AbstractLauncherIcon::GetQuirk ( Quirk  quirk) const [pure virtual]
virtual struct timespec unity::launcher::AbstractLauncherIcon::GetQuirkTime ( Quirk  quirk) [read, pure virtual]
virtual nux::Point3 unity::launcher::AbstractLauncherIcon::GetSavedCenter ( int  monitor) [pure virtual]
virtual guint64 unity::launcher::AbstractLauncherIcon::GetShortcut ( ) [pure virtual]
std::vector< nux::Vector4 > & unity::ui::IconTextureSource::GetTransform ( TransformIndex  index,
int  monitor 
) [inherited]

Definition at line 34 of file IconTextureSource.cpp.

{
  auto iter = transform_map[monitor].find(index);
  if (iter == transform_map[monitor].end())
  {
    auto iter2 = transform_map[monitor].insert(std::map<TransformIndex, std::vector<nux::Vector4> >::value_type(index, std::vector<nux::Vector4>(4)));
    return iter2.first->second;
  }

  return iter->second;
}

Here is the caller graph for this function:

virtual nux::Color unity::ui::IconTextureSource::GlowColor ( ) [pure virtual, inherited]
virtual void unity::launcher::AbstractLauncherIcon::HideTooltip ( ) [pure virtual]
GVariant * unity::debug::Introspectable::Introspect ( ) [inherited]

Definition at line 47 of file Introspectable.cpp.

{
  GVariantBuilder  builder;
  GVariantBuilder  child_builder;
  gint             n_children = 0;

  g_variant_builder_init(&builder, G_VARIANT_TYPE("a{sv}"));
  g_variant_builder_add(&builder, "{sv}", "id", g_variant_new_uint64(_id));

  AddProperties(&builder);

  g_variant_builder_init(&child_builder, G_VARIANT_TYPE("as"));

  auto children = GetIntrospectableChildren();
  for (auto it = children.begin(); it != children.end(); it++)
  {
    if ((*it)->GetName() != "")
    {
      g_variant_builder_add(&child_builder, "s", (*it)->GetName().c_str());
      n_children++;
    }
  }

  GVariant* child_results = g_variant_builder_end(&child_builder);

  if (n_children > 0)
    g_variant_builder_add(&builder, "{sv}", GetChildsName().c_str(), child_results);
  return g_variant_builder_end(&builder);
}

Here is the call graph for this function:

virtual bool unity::launcher::AbstractLauncherIcon::IsSpacer ( ) [pure virtual]
virtual bool unity::launcher::AbstractLauncherIcon::IsSticky ( ) const [pure virtual]
virtual bool unity::launcher::AbstractLauncherIcon::IsVisible ( ) const [pure virtual]
virtual bool unity::launcher::AbstractLauncherIcon::IsVisibleOnMonitor ( int  monitor) const [pure virtual]
virtual std::list<DbusmenuMenuitem*> unity::launcher::AbstractLauncherIcon::Menus ( ) [pure virtual]
virtual std::string unity::launcher::AbstractLauncherIcon::NameForWindow ( Window  window) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::OpenInstance ( ActionArg  arg) [pure virtual]
virtual bool unity::launcher::AbstractLauncherIcon::OpenQuicklist ( bool  select_first_item = false,
int  monitor = -1 
) [pure virtual]
virtual nux::DndAction unity::launcher::AbstractLauncherIcon::QueryAcceptDrop ( DndData const &  dnd_data) [pure virtual]
virtual std::string unity::launcher::AbstractLauncherIcon::RemoteUri ( ) [pure virtual]

Definition at line 85 of file Introspectable.cpp.

{
  _children.remove(child);
  child->_parents.remove(this);
}

Here is the caller graph for this function:

virtual void unity::launcher::AbstractLauncherIcon::ResetQuirkTime ( Quirk  quirk) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SaveCenter ( ) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SendDndEnter ( ) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SendDndLeave ( ) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SetCenter ( nux::Point3  center,
int  monitor,
nux::Geometry  parent_geo 
) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SetQuirk ( Quirk  quirk,
bool  value 
) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SetShortcut ( guint64  shortcut) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SetSortPriority ( int  priority) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::SetVisibleOnMonitor ( int  monitor,
bool  visible 
) [pure virtual]
virtual bool unity::launcher::AbstractLauncherIcon::ShouldHighlightOnDrag ( DndData const &  dnd_data) [pure virtual]
virtual bool unity::launcher::AbstractLauncherIcon::ShowInSwitcher ( bool  current) [pure virtual]
virtual void unity::launcher::AbstractLauncherIcon::Stick ( bool  save = true) [pure virtual]
virtual unsigned long long unity::launcher::AbstractLauncherIcon::SwitcherPriority ( ) [pure virtual]
virtual nux::BaseTexture* unity::ui::IconTextureSource::TextureForSize ( int  size) [pure virtual, inherited]

Implemented in unity::launcher::MockLauncherIcon, unity::launcher::LauncherIcon, and unity::hud::HudIconTextureSource.

Here is the caller graph for this function:

virtual void unity::launcher::AbstractLauncherIcon::UnStick ( ) [pure virtual]
virtual std::vector<Window> unity::launcher::AbstractLauncherIcon::Windows ( ) [pure virtual]
virtual std::vector<Window> unity::launcher::AbstractLauncherIcon::WindowsForMonitor ( int  monitor) [pure virtual]
virtual std::vector<Window> unity::launcher::AbstractLauncherIcon::WindowsOnViewport ( ) [pure virtual]
virtual const bool unity::launcher::AbstractLauncherIcon::WindowVisibleOnMonitor ( int  monitor) [pure virtual]

Member Data Documentation

sigc::signal<void, int, int, unsigned long> unity::launcher::AbstractLauncherIcon::mouse_click

Definition at line 215 of file AbstractLauncherIcon.h.

sigc::signal<void, int, int, unsigned long> unity::launcher::AbstractLauncherIcon::mouse_down

Definition at line 213 of file AbstractLauncherIcon.h.

Definition at line 216 of file AbstractLauncherIcon.h.

Definition at line 217 of file AbstractLauncherIcon.h.

sigc::signal<void, int, int, unsigned long> unity::launcher::AbstractLauncherIcon::mouse_up

Definition at line 214 of file AbstractLauncherIcon.h.

Definition at line 219 of file AbstractLauncherIcon.h.

Definition at line 224 of file AbstractLauncherIcon.h.

Definition at line 228 of file AbstractLauncherIcon.h.

Definition at line 225 of file AbstractLauncherIcon.h.

Definition at line 226 of file AbstractLauncherIcon.h.

Definition at line 227 of file AbstractLauncherIcon.h.

Definition at line 220 of file AbstractLauncherIcon.h.

Definition at line 122 of file AbstractLauncherIcon.h.

Definition at line 121 of file AbstractLauncherIcon.h.

sigc::signal<void, nux::ObjectPtr<nux::View> > unity::launcher::AbstractLauncherIcon::tooltip_visible

Definition at line 221 of file AbstractLauncherIcon.h.

Definition at line 222 of file AbstractLauncherIcon.h.


The documentation for this class was generated from the following file: