Changeset View
Changeset View
Standalone View
Standalone View
plugins/dockers/advancedcolorselector/kis_color_selector.cpp
Show First 20 Lines • Show All 143 Lines • ▼ Show 20 Line(s) | |||||
144 | { | 144 | { | ||
145 | return m_configuration; | 145 | return m_configuration; | ||
146 | } | 146 | } | ||
147 | 147 | | |||
148 | void KisColorSelector::updateSettings() | 148 | void KisColorSelector::updateSettings() | ||
149 | { | 149 | { | ||
150 | KisColorSelectorBase::updateSettings(); | 150 | KisColorSelectorBase::updateSettings(); | ||
151 | KConfigGroup cfg = KSharedConfig::openConfig()->group("advancedColorSelector"); | 151 | KConfigGroup cfg = KSharedConfig::openConfig()->group("advancedColorSelector"); | ||
152 | | ||||
152 | setConfiguration(KisColorSelectorConfiguration::fromString(cfg.readEntry("colorSelectorConfiguration", KisColorSelectorConfiguration().toString()))); | 153 | setConfiguration(KisColorSelectorConfiguration::fromString(cfg.readEntry("colorSelectorConfiguration", KisColorSelectorConfiguration().toString()))); | ||
153 | } | 154 | } | ||
154 | 155 | | |||
156 | void KisColorSelector::slotGamutMaskSet(KoGamutMask *gamutMask) | ||||
157 | { | ||||
158 | m_mainComponent->setGamutMask(gamutMask); | ||||
159 | m_subComponent->setGamutMask(gamutMask); | ||||
160 | | ||||
161 | slotGamutMaskToggle(true); | ||||
162 | } | ||||
163 | | ||||
164 | void KisColorSelector::slotGamutMaskUnset() | ||||
165 | { | ||||
166 | m_mainComponent->unsetGamutMask(); | ||||
167 | m_subComponent->unsetGamutMask(); | ||||
168 | | ||||
169 | slotGamutMaskToggle(false); | ||||
170 | } | ||||
171 | | ||||
172 | void KisColorSelector::slotGamutMaskPreviewUpdate() | ||||
173 | { | ||||
174 | m_mainComponent->updateGamutMaskPreview(); | ||||
175 | m_subComponent->updateGamutMaskPreview(); | ||||
176 | } | ||||
177 | | ||||
178 | void KisColorSelector::slotGamutMaskToggle(bool state) | ||||
179 | { | ||||
180 | m_mainComponent->toggleGamutMask(state); | ||||
181 | m_subComponent->toggleGamutMask(state); | ||||
182 | } | ||||
183 | | ||||
155 | void KisColorSelector::updateIcons() { | 184 | void KisColorSelector::updateIcons() { | ||
156 | if (m_button) { | 185 | if (m_button) { | ||
157 | m_button->setIcon(KisIconUtils::loadIcon("configure")); | 186 | m_button->setIcon(KisIconUtils::loadIcon("configure")); | ||
158 | } | 187 | } | ||
159 | } | 188 | } | ||
160 | 189 | | |||
161 | void KisColorSelector::hasAtLeastOneDocument(bool value) | 190 | void KisColorSelector::hasAtLeastOneDocument(bool value) | ||
162 | { | 191 | { | ||
▲ Show 20 Lines • Show All 204 Lines • Show Last 20 Lines |