Back to index

unity  6.0.0
Public Types | Public Member Functions | Public Attributes
unity::shortcut::MockHint Class Reference

#include <MockShortcutHint.h>

Inheritance diagram for unity::shortcut::MockHint:
Inheritance graph
[legend]
Collaboration diagram for unity::shortcut::MockHint:
Collaboration graph
[legend]

List of all members.

Public Types

typedef std::shared_ptr
< AbstractHint
Ptr

Public Member Functions

 MockHint (std::string const &category, std::string const &prefix, std::string const &postfix, std::string const &description, OptionType const type, std::string const &arg1, std::string const &arg2="", std::string const &arg3="")
 ~MockHint ()
bool Fill ()

Public Attributes

nux::Property< std::string > category
nux::Property< std::string > prefix
nux::Property< std::string > postfix
nux::Property< std::string > description
nux::Property< OptionTypetype
nux::Property< std::string > arg1
nux::Property< std::string > arg2
nux::Property< std::string > arg3
nux::Property< std::string > value
nux::Property< std::string > shortkey

Detailed Description

Definition at line 30 of file MockShortcutHint.h.


Member Typedef Documentation

typedef std::shared_ptr<AbstractHint> unity::shortcut::AbstractHint::Ptr [inherited]

Definition at line 46 of file AbstractShortcutHint.h.


Constructor & Destructor Documentation

unity::shortcut::MockHint::MockHint ( std::string const &  category,
std::string const &  prefix,
std::string const &  postfix,
std::string const &  description,
OptionType const  type,
std::string const &  arg1,
std::string const &  arg2 = "",
std::string const &  arg3 = "" 
) [inline]

Definition at line 34 of file MockShortcutHint.h.

Definition at line 46 of file MockShortcutHint.h.

{};

Member Function Documentation

bool unity::shortcut::MockHint::Fill ( ) [inline, virtual]

Implements unity::shortcut::AbstractHint.

Definition at line 49 of file MockShortcutHint.h.

  {
    switch (type())
    {
      case COMPIZ_MOUSE_OPTION:
      case COMPIZ_KEY_OPTION:
      case COMPIZ_METAKEY_OPTION:
        value = arg1() + "-" + arg2();
        shortkey = prefix() + value() + postfix();
        return true;
      
      case HARDCODED_OPTION:
        value = arg1();
        shortkey = prefix() + value() + postfix();
        return true;
    }
    
    return false;
  }

Member Data Documentation

nux::Property<std::string> unity::shortcut::AbstractHint::arg1 [inherited]

Definition at line 94 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::arg2 [inherited]

Definition at line 95 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::arg3 [inherited]

Definition at line 96 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::category [inherited]

Definition at line 89 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::description [inherited]

Definition at line 92 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::postfix [inherited]

Definition at line 91 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::prefix [inherited]

Definition at line 90 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::shortkey [inherited]

Definition at line 98 of file AbstractShortcutHint.h.

nux::Property<OptionType> unity::shortcut::AbstractHint::type [inherited]

Definition at line 93 of file AbstractShortcutHint.h.

nux::Property<std::string> unity::shortcut::AbstractHint::value [inherited]

Definition at line 97 of file AbstractShortcutHint.h.


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