Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: Array_Matrix TS_DISCO_F746NG LCD_DISCO_F746NG BSP_DISCO_F746NG
Revision 13:9ae055fac9cf, committed 2016-05-30
- Comitter:
- MikamiUitOpen
- Date:
- Mon May 30 14:34:44 2016 +0000
- Parent:
- 12:687ec6183385
- Child:
- 14:b977160de2f3
- Commit message:
- 14
Changed in this revision
| SeekBar.hpp | Show annotated file Show diff for this revision Revisions of this file |
| SeekbarGroup.hpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/SeekBar.hpp Sat Apr 30 06:33:32 2016 +0000
+++ b/SeekBar.hpp Mon May 30 14:34:44 2016 +0000
@@ -1,7 +1,7 @@
//-----------------------------------------------------------
// SeekBar class -- Header
//
-// 2016/04/30, Copyright (c) 2016 MIKAMI, Naoki
+// 2016/05/30, Copyright (c) 2016 MIKAMI, Naoki
//-----------------------------------------------------------
#ifndef F746_SEEKBAR_HPP
@@ -67,8 +67,6 @@
void SetSlided(bool tf) { slided_ = tf; }
bool GetSlided() { return slided_; }
- int Round(float x) { return x + 0.5f - (x < 0); } // Round up on 5
-
private:
const uint16_t L_, W_;
const uint16_t SIZE_; // Size of thumb
@@ -82,6 +80,7 @@
bool slided_;
bool active_;
+ int Round(float x) { return x + 0.5f - (x < 0); }
Point ToPoint(float value);
float Saturate(float value);
@@ -91,3 +90,4 @@
};
}
#endif // F746_SEEKBAR_HPP
+
--- a/SeekbarGroup.hpp Sat Apr 30 06:33:32 2016 +0000
+++ b/SeekbarGroup.hpp Mon May 30 14:34:44 2016 +0000
@@ -1,7 +1,7 @@
//-----------------------------------------------------------
// SeekbarGroup class -- Header
//
-// 2016/04/30, Copyright (c) 2016 MIKAMI, Naoki
+// 2016/05/30, Copyright (c) 2016 MIKAMI, Naoki
//-----------------------------------------------------------
#ifndef F746_SEEKBAR_GROUP_HPP
@@ -28,7 +28,7 @@
bool Slide(int num) { return seekBars_[num]->Slide(); }
float GetValue(int num) { return seekBars_[num]->GetValue(); }
- int GetIntValue(int num) { return seekBars_[num]->Round(seekBars_[num]->GetIntValue()); }
+ int GetIntValue(int num) { return seekBars_[num]->GetIntValue(); }
// Get slided number
bool GetSlidedNumber(int &num);