Local adjustments tools used globally - Laspotmain (#6928)
* First step LA globally * fixed several GUI bad behavior * better behavior shows additional settings * Improve transition in main * First step hide-show invers and scope * Hide show invers and scope step2 * hide show others inverse and scope * Try to improve * Change windows.yml and appimage.yml * In Preference set choice for default Spot Method * Optimization call idle_register * forgotten delete mainfp * Re-enable sliders scope in colorlight - shadows - vibrance - move setting checkbox others settings * Fixed bad behavior hide - show * Optimize behavior * Bad behavior scope when changing method * Clean and comment code * disable preview mask and modif for cbdl and retinex * Fixed preview deltaE mask and modif log encode - exposure - new button preview color and light * Button preview deltaE - exposure * Button preview SH * Button preview Vibrance * Improce code using mask * Fixed several bad behavior - preview TM and Contrast * Preview log button * Preview Ciecam button * Preview common mask button * Disable Preview button in settings when not used in tools * Change call to controspotpanel in improcoordinator * Change Local adjustments title to Selective Editing * Change default value spotmethod in option * Missing cddl in preview settings * Change parameter setting spot type * put selective editing tab just after exposure tab * Disable preview ΔE button when another is enabled Only one button should be active at any given time. * Deactivate preview ΔE buttons when switching spots * Change tooltip Spot method * Change selective editing position * Remove duplicate line in language default * Remove appimage.yml windows.yml --------- Co-authored-by: Lawrence Lee <45837045+Lawrence37@users.noreply.github.com>
This commit is contained in:
@@ -2028,3 +2028,42 @@ void SpotPicker::spotSizeChanged()
|
||||
{
|
||||
_spotHalfWidth = atoi(_spotSizeSetter.get_active_text().c_str());
|
||||
}
|
||||
|
||||
// OptionalRadioButtonGroup class
|
||||
|
||||
void OptionalRadioButtonGroup::onButtonToggled(Gtk::ToggleButton *button)
|
||||
{
|
||||
if (!button) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (button->get_active()) {
|
||||
if (active_button == button) {
|
||||
// Same button, noting to do.
|
||||
} else if (active_button) {
|
||||
// Deactivate the other button.
|
||||
active_button->set_active(false);
|
||||
}
|
||||
active_button = button;
|
||||
} else {
|
||||
if (active_button == button) {
|
||||
// Active button got deactivated.
|
||||
active_button = nullptr;
|
||||
} else {
|
||||
// No effect on other buttons.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Gtk::ToggleButton *OptionalRadioButtonGroup::getActiveButton() const
|
||||
{
|
||||
return active_button;
|
||||
}
|
||||
|
||||
void OptionalRadioButtonGroup::register_button(Gtk::ToggleButton &button)
|
||||
{
|
||||
button.signal_toggled().connect(sigc::bind(
|
||||
sigc::mem_fun(this, &OptionalRadioButtonGroup::onButtonToggled),
|
||||
&button));
|
||||
onButtonToggled(&button);
|
||||
}
|
||||
|
Reference in New Issue
Block a user