/*********************************************************************************/ /********** THIS FILE IS GENERATED BY TOUCHGFX DESIGNER, DO NOT MODIFY ***********/ /*********************************************************************************/ #include #include #include #include ReverbViewBase::ReverbViewBase() : buttonCallback(this, &ReverbViewBase::buttonCallbackHandler), sliderValueChangedCallback(this, &ReverbViewBase::sliderValueChangedCallbackHandler) { __background.setPosition(0, 0, 800, 480); __background.setColor(touchgfx::Color::getColorFromRGB(0, 0, 0)); add(__background); image1.setXY(0, -1); image1.setBitmap(touchgfx::Bitmap(BITMAP_FONDHORLOGERIE1_ID)); add(image1); box1.setPosition(0, 0, 800, 480); box1.setColor(touchgfx::Color::getColorFromRGB(35, 24, 15)); box1.setAlpha(240); add(box1); textArea2.setXY(142, 380); textArea2.setColor(touchgfx::Color::getColorFromRGB(230, 214, 170)); textArea2.setLinespacing(0); textArea2.setTypedText(touchgfx::TypedText(T_MIX)); add(textArea2); textArea2_1.setXY(130, 271); textArea2_1.setColor(touchgfx::Color::getColorFromRGB(230, 214, 170)); textArea2_1.setLinespacing(0); textArea2_1.setTypedText(touchgfx::TypedText(T_DAMPING)); add(textArea2_1); textArea2_2.setXY(130, 161); textArea2_2.setColor(touchgfx::Color::getColorFromRGB(230, 214, 170)); textArea2_2.setLinespacing(0); textArea2_2.setTypedText(touchgfx::TypedText(T_DRIVE)); add(textArea2_2); slider1.setXY(280, 145); slider1.setBitmaps(touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_TRACK_LARGE_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_FILLER_LARGE_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_ROUNDED_DARK_ID)); slider1.setupHorizontalSlider(28, 21, 0, 0, 400); slider1.setValueRange(0, 100); slider1.setValue(0); slider1.setNewValueCallback(sliderValueChangedCallback); add(slider1); slider2.setXY(280, 255); slider2.setBitmaps(touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_TRACK_LARGE_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_FILLER_LARGE_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_ROUNDED_DARK_ID)); slider2.setupHorizontalSlider(28, 21, 0, 0, 400); slider2.setValueRange(0, 100); slider2.setValue(0); slider2.setNewValueCallback(sliderValueChangedCallback); add(slider2); slider3.setXY(280, 365); slider3.setBitmaps(touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_TRACK_LARGE_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_FILLER_LARGE_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_SLIDER_HORIZONTAL_THICK_ROUNDED_DARK_ID)); slider3.setupHorizontalSlider(28, 21, 0, 0, 400); slider3.setValueRange(0, 100); slider3.setValue(0); slider3.setNewValueCallback(sliderValueChangedCallback); add(slider3); textArea1.setXY(317, 27); textArea1.setColor(touchgfx::Color::getColorFromRGB(230, 214, 170)); textArea1.setLinespacing(0); textArea1.setTypedText(touchgfx::TypedText(T_REVERB)); add(textArea1); buttonWithLabel1.setXY(0, 0); buttonWithLabel1.setBitmaps(touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_BUTTON_REGULAR_HEIGHT_50_SMALL_ROUNDED_NORMAL_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_BUTTON_REGULAR_HEIGHT_50_SMALL_ROUNDED_PRESSED_ID)); buttonWithLabel1.setLabelText(touchgfx::TypedText(T_BACK)); buttonWithLabel1.setLabelColor(touchgfx::Color::getColorFromRGB(230, 214, 170)); buttonWithLabel1.setLabelColorPressed(touchgfx::Color::getColorFromRGB(230, 214, 170)); buttonWithLabel1.setAction(buttonCallback); add(buttonWithLabel1); toggleButton1.setXY(576, 20); toggleButton1.setBitmaps(touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_TOGGLEBUTTON_LARGE_ROUND_TEXT_OFF_NORMAL_ID), touchgfx::Bitmap(BITMAP_GLASS_THEME_IMAGES_WIDGETS_TOGGLEBUTTON_LARGE_ROUND_TEXT_ON_ACTIVE_ID)); toggleButton1.setAction(buttonCallback); add(toggleButton1); } ReverbViewBase::~ReverbViewBase() { } void ReverbViewBase::setupScreen() { } void ReverbViewBase::buttonCallbackHandler(const touchgfx::AbstractButton& src) { if (&src == &buttonWithLabel1) { //Interaction1 //When buttonWithLabel1 clicked change screen to Overview //Go to Overview with no screen transition application().gotoOverviewScreenNoTransition(); } if (&src == &toggleButton1) { //Interaction2 //When toggleButton1 clicked call virtual function //Call toggleClicked toggleClicked(); } } void ReverbViewBase::sliderValueChangedCallbackHandler(const touchgfx::Slider& src, int value) { if (&src == &slider1) { //Interaction3 //When slider1 value changed call virtual function //Call sliderTailleChanged sliderTailleChanged(value); } if (&src == &slider2) { //Interaction4 //When slider2 value changed call virtual function //Call sliderAmortiChanged sliderAmortiChanged(value); } if (&src == &slider3) { //Interaction5 //When slider3 value changed call virtual function //Call sliderMixChanged sliderMixChanged(value); } }