From 9ebf5261fa6d848be73f124e24cc44b3d1e62542 Mon Sep 17 00:00:00 2001 From: vanhofen Date: Mon, 30 May 2016 11:21:22 +0200 Subject: [PATCH] setting_helpers: whitespace cleanup and code format changes Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/30a3093d9fc13e816c8ca3b6c663d1179a7bbd3b Author: vanhofen Date: 2016-05-30 (Mon, 30 May 2016) Origin message was: ------------------ - setting_helpers: whitespace cleanup and code format changes ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- src/system/setting_helpers.cpp | 8 ++++---- src/system/setting_helpers.h | 35 ++++++++++++++++------------------ 2 files changed, 20 insertions(+), 23 deletions(-) diff --git a/src/system/setting_helpers.cpp b/src/system/setting_helpers.cpp index 7c098a086..9a0bd59e9 100644 --- a/src/system/setting_helpers.cpp +++ b/src/system/setting_helpers.cpp @@ -401,7 +401,7 @@ long CNetAdapter::mac_addr_sys ( u_char *addr) //only for function getMacAddr() int s, i; int ok = 0; s = socket(AF_INET, SOCK_DGRAM, 0); - if (s==-1) + if (s==-1) { return -1; } @@ -413,11 +413,11 @@ long CNetAdapter::mac_addr_sys ( u_char *addr) //only for function getMacAddr() for (i = ifc.ifc_len / sizeof(struct ifreq); --i >= 0; IFR++) { strcpy(ifr.ifr_name, IFR->ifr_name); - if (ioctl(s, SIOCGIFFLAGS, &ifr) == 0) + if (ioctl(s, SIOCGIFFLAGS, &ifr) == 0) { - if (! (ifr.ifr_flags & IFF_LOOPBACK)) + if (! (ifr.ifr_flags & IFF_LOOPBACK)) { - if (ioctl(s, SIOCGIFHWADDR, &ifr) == 0) + if (ioctl(s, SIOCGIFHWADDR, &ifr) == 0) { ok = 1; break; diff --git a/src/system/setting_helpers.h b/src/system/setting_helpers.h index 50ea5ef6c..98be19f84 100644 --- a/src/system/setting_helpers.h +++ b/src/system/setting_helpers.h @@ -69,19 +69,16 @@ class COnOffNotifier : public CChangeObserver class CSectionsdConfigNotifier : public CChangeObserver { - public: - bool changeNotify(const neutrino_locale_t, void * ); + public: + bool changeNotify(const neutrino_locale_t, void * ); }; class CTouchFileNotifier : public CChangeObserver { const char * filename; - public: - inline CTouchFileNotifier(const char * file_to_modify) - { - filename = file_to_modify; - }; - bool changeNotify(const neutrino_locale_t, void * data); + public: + inline CTouchFileNotifier(const char * _filename) { filename = _filename; }; + bool changeNotify(const neutrino_locale_t, void * data); }; class CColorSetupNotifier : public CChangeObserver @@ -123,33 +120,33 @@ class CMoviePluginChangeExec : public CMenuTarget class CTZChangeNotifier : public CChangeObserver { -public: - bool changeNotify(const neutrino_locale_t, void * data); + public: + bool changeNotify(const neutrino_locale_t, void * data); }; class CDataResetNotifier : public CMenuTarget { -public: - int exec(CMenuTarget* parent, const std::string& actionKey); + public: + int exec(CMenuTarget* parent, const std::string& actionKey); }; class CFanControlNotifier : public CChangeObserver { -public: - bool changeNotify(const neutrino_locale_t, void * data); - static void setSpeed(unsigned int speed); + public: + bool changeNotify(const neutrino_locale_t, void * data); + static void setSpeed(unsigned int speed); }; class CCpuFreqNotifier : public CChangeObserver { -public: - bool changeNotify(const neutrino_locale_t, void * data); + public: + bool changeNotify(const neutrino_locale_t, void * data); }; class CAutoModeNotifier : public CChangeObserver { -public: - bool changeNotify(const neutrino_locale_t, void * data); + public: + bool changeNotify(const neutrino_locale_t, void * data); }; #endif