Edit:
// "OnOffTest" bestimmt ob leder/Stoff
noStroke();
if (OnOffTest.myStateActive) {
image(myImage2,350, 110);
} else {
image(myImage1,350, 110);
}
// "tabButtonTest" bestimmt 3 farbvarianten
if (OnOffTest.myStateActive) {
if (tabButtonTest.activeTab == 0) {
image(myImage2, 350, 110);
} else if (tabButtonTest.activeTab == 1) {
image(myImage4, 350, 110);
} else if (tabButtonTest.activeTab == 2) {
image(myImage5, 350, 110);
}
}
// "tabButtonTest2" bestimmt 3 farbvarianten
if (OnOffTest.myStateActive) {
if (tabButtonTest.activeTab == 0) {
if (tabButtonTest2.activeTab == 0) {
image(myImage5, 350, 110);
}
else if (tabButtonTest2.activeTab == 1) {
image(myImage7, 350, 110);
}
else if (tabButtonTest2.activeTab == 2) {
image(myImage6, 350, 110);
}
}
}
if (OnOffTest.myStateActive) {
if (tabButtonTest.activeTab == 1) {
if (tabButtonTest2.activeTab == 0) {
image(myImage4, 350, 110);
}
else if (tabButtonTest2.activeTab == 1) {
image(myImage9, 350, 110);
}
else if (tabButtonTest2.activeTab == 2) {
image(myImage8, 350, 110);
}
}
}
if (OnOffTest.myStateActive) {
if (tabButtonTest.activeTab == 2) {
if (tabButtonTest2.activeTab == 0) {
image(myImage2, 350, 110);
}
else if (tabButtonTest2.activeTab == 1) {
image(myImage11, 350, 110);
}
else if (tabButtonTest2.activeTab == 2) {
image(myImage10, 350, 110);
}
}
}
Now the first variation for fabric works. All combinations work.
But i dont know how i write the next part so if the toggle button is on the “other side” for leather.
In the first part i wrote everytime
if (OnOffTest.myStateActive) {
In front of the tabbutton.
Whats the opposite for that? so its only for the “leather side”