Manual input source select via json (#143)

* implement manual source select via json interface
fix schema error

* refactoring

* add visible value to all listed prios
This commit is contained in:
redPanther
2016-07-31 22:21:35 +02:00
committed by GitHub
parent 04ab2f05f7
commit 722d4eb357
14 changed files with 208 additions and 47 deletions

View File

@@ -128,7 +128,22 @@ public:
/// @param name uniq name of input source
void unRegisterPriority(const std::string name);
/// gets current priority register
/// @return the priority register
const PriorityRegister& getPriorityRegister() { return _priorityRegister; }
/// enable/disable automatic/priorized source selection
/// @param enable the state
void setSourceAutoSelectEnabled(bool enabled);
/// set current input source to visible
/// @param priority the priority channel which should be vidible
/// @return true if success, false on error
bool setCurrentSourcePriority(int priority );
/// gets current state of automatic/priorized source selection
/// @return the state
bool sourceAutoSelectEnabled() { return _sourceAutoSelectEnabled; };
public slots:
///
/// Writes a single color to all the leds for the given time and priority
@@ -326,7 +341,18 @@ private:
/// register of input sources and it's prio channel
PriorityRegister _priorityRegister;
/// flag for color transform enable
bool _transformEnabled;
/// flag for color adjustment enable
bool _adjustmentEnabled;
/// flag for color temperature enable
bool _temperatureEnabled;
/// flag indicates state for autoselection of input source
bool _sourceAutoSelectEnabled;
/// holds the current priority channel that is manualy selected
int _currentSourcePriority;
};