mirror of
https://github.com/itead/ITEADLIB_Arduino_Nextion.git
synced 2026-03-06 18:16:49 +01:00
Modified:char *name to const char *name in all constructors.
Signed-off-by: shennongmin <wupangfee@gmail.com>
This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexButton::NexButton(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
NexButton::NexButton(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
:NexTouch(pid, cid, name, pop, pop_ptr)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexButton: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexButton(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
NexButton(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
|
||||
void attachPop(NexTouchEventCb pop, void *ptr = NULL);
|
||||
void detachPop(void);
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexCrop::NexCrop(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
NexCrop::NexCrop(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
:NexTouch(pid, cid, name, pop, pop_ptr)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexCrop: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexCrop(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
NexCrop(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
|
||||
void attachPop(NexTouchEventCb pop, void *ptr = NULL);
|
||||
void detachPop(void);
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexGauge::NexGauge(NexPid pid, NexCid cid, char *name)
|
||||
NexGauge::NexGauge(NexPid pid, NexCid cid, const char *name)
|
||||
:NexTouch(pid, cid, name)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexGauge: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexGauge(NexPid pid, NexCid cid, char *name);
|
||||
NexGauge(NexPid pid, NexCid cid, const char *name);
|
||||
|
||||
bool getValue(uint32_t *number);
|
||||
bool setValue(uint32_t number);
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexHotspot::NexHotspot(NexPid pid, NexCid cid, char *name,
|
||||
NexHotspot::NexHotspot(NexPid pid, NexCid cid, const char *name,
|
||||
NexTouchEventCb pop, void *pop_ptr,
|
||||
NexTouchEventCb push, void *push_ptr)
|
||||
:NexTouch(pid, cid, name, pop, pop_ptr, push, push_ptr)
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexHotspot: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexHotspot(NexPid pid, NexCid cid, char *name,
|
||||
NexHotspot(NexPid pid, NexCid cid, const char *name,
|
||||
NexTouchEventCb pop = NULL, void *pop_ptr = NULL,
|
||||
NexTouchEventCb push = NULL, void *push_ptr = NULL);
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexPage::NexPage(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
NexPage::NexPage(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
:NexTouch(pid, cid, name, pop, pop_ptr)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexPage: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexPage(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
NexPage(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
bool show(void);
|
||||
|
||||
void attachPop(NexTouchEventCb pop, void *ptr = NULL);
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexPicture::NexPicture(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
NexPicture::NexPicture(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
:NexTouch(pid, cid, name, pop, pop_ptr)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexPicture: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexPicture(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
NexPicture(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
|
||||
void attachPop(NexTouchEventCb pop, void *ptr = NULL);
|
||||
void detachPop(void);
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexProgressBar::NexProgressBar(NexPid pid, NexCid cid, char *name)
|
||||
NexProgressBar::NexProgressBar(NexPid pid, NexCid cid, const char *name)
|
||||
:NexTouch(pid, cid, name)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexProgressBar: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexProgressBar(NexPid pid, NexCid cid, char *name);
|
||||
NexProgressBar(NexPid pid, NexCid cid, const char *name);
|
||||
|
||||
bool getValue(uint32_t *number);
|
||||
bool setValue(uint32_t number);
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexSlider::NexSlider(NexPid pid, NexCid cid, char *name,
|
||||
NexSlider::NexSlider(NexPid pid, NexCid cid, const char *name,
|
||||
NexTouchEventCb pop, void *pop_ptr)
|
||||
:NexTouch(pid, cid, name, pop, pop_ptr)
|
||||
{
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexSlider: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexSlider(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
NexSlider(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
|
||||
void attachPop(NexTouchEventCb pop, void *ptr = NULL);
|
||||
void detachPop(void);
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexText::NexText(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
NexText::NexText(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop, void *pop_ptr)
|
||||
:NexTouch(pid, cid, name, pop, pop_ptr)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
class NexText: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexText(NexPid pid, NexCid cid, char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
NexText(NexPid pid, NexCid cid, const char *name, NexTouchEventCb pop = NULL, void *pop_ptr = NULL);
|
||||
|
||||
void attachPop(NexTouchEventCb pop, void *ptr = NULL);
|
||||
void detachPop(void);
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
* @param push_ptr - the parameter was transmitted to push event function pointer.
|
||||
*
|
||||
*/
|
||||
NexTouch::NexTouch(NexPid pid, NexCid cid, char *name,
|
||||
NexTouch::NexTouch(NexPid pid, NexCid cid, const char *name,
|
||||
NexTouchEventCb pop, void *pop_ptr,
|
||||
NexTouchEventCb push, void *push_ptr)
|
||||
{
|
||||
|
||||
@@ -40,7 +40,7 @@ public: /* static methods */
|
||||
static void iterate(NexTouch **list, NexPid pid, NexCid cid, NexEventType event);
|
||||
|
||||
public: /* methods */
|
||||
NexTouch(NexPid pid, NexCid cid, char *name,
|
||||
NexTouch(NexPid pid, NexCid cid, const char *name,
|
||||
NexTouchEventCb pop = NULL, void *pop_ptr = NULL,
|
||||
NexTouchEventCb push = NULL, void *push_ptr = NULL);
|
||||
|
||||
@@ -62,7 +62,7 @@ private: /* methods */
|
||||
private: /* data */
|
||||
NexPid pid; /* Page ID */
|
||||
NexCid cid; /* Component ID */
|
||||
char *name; /* An unique name */
|
||||
const char *name; /* An unique name */
|
||||
NexTouchEventCb cbPush;
|
||||
void *__cbpush_ptr;
|
||||
NexTouchEventCb cbPop;
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Constructor,inherited NexTouch's constructor function.
|
||||
*
|
||||
*/
|
||||
NexWaveform::NexWaveform(NexPid pid, NexCid cid, char *name)
|
||||
NexWaveform::NexWaveform(NexPid pid, NexCid cid, const char *name)
|
||||
:NexTouch(pid, cid, name)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
class NexWaveform: public NexTouch
|
||||
{
|
||||
public: /* methods */
|
||||
NexWaveform(NexPid pid, NexCid cid, char *name);
|
||||
NexWaveform(NexPid pid, NexCid cid, const char *name);
|
||||
bool addValue(uint8_t ch, uint8_t number);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user