Commit cfaec801 authored by Halla Rempt's avatar Halla Rempt

Rename KoPatternChooser to KisPatternChooser

Since it's in kis_pattern_chooser.* after all.
parent e2378422
......@@ -30,7 +30,7 @@
PatternDockerDock::PatternDockerDock( )
: QDockWidget(i18n("Patterns"))
{
m_patternChooser = new KoPatternChooser(this);
m_patternChooser = new KisPatternChooser(this);
m_patternChooser->setPreviewOrientation(Qt::Vertical);
m_patternChooser->setCurrentItem(0,0);
m_patternChooser->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred);
......
......@@ -22,7 +22,7 @@
#include <kis_mainwindow_observer.h>
class KoPattern;
class KoPatternChooser;
class KisPatternChooser;
class PatternDockerDock : public QDockWidget, public KisMainwindowObserver {
Q_OBJECT
......@@ -39,7 +39,7 @@ public slots:
private slots:
private:
KoPatternChooser* m_patternChooser;
KisPatternChooser* m_patternChooser;
};
......
......@@ -53,7 +53,6 @@ void KisWdgPattern::setConfiguration(const KisPropertiesConfiguration* config)
if (pattern) {
widget()->patternChooser->setCurrentPattern(pattern);
}
// widget()->bnColor->setColor(config->getColor("color").toQColor());
}
......@@ -64,11 +63,6 @@ KisPropertiesConfiguration* KisWdgPattern::configuration() const
v.setValue(widget()->patternChooser->currentResource()->name());
config->setProperty("pattern", v);
// KoColor c;
// c.fromQColor(this->widget()->bnColor->color());
// v.setValue(c);
// config->setProperty("color", v);
return config;
}
......@@ -59,7 +59,7 @@ public:
QFormLayout *formLayout = new QFormLayout(this);
formLayout->setMargin(0);
chooser = new KoPatternChooser(this);
chooser = new KisPatternChooser(this);
chooser->setGrayscalePreview(true);
chooser->setMaximumHeight(250);
chooser->setCurrentItem(0, 0);
......@@ -120,7 +120,7 @@ public:
setLayout(formLayout);
}
KoPatternChooser *chooser;
KisPatternChooser *chooser;
KisMultipliersDoubleSliderSpinBox *scaleSlider;
KisSliderSpinBox *offsetSliderX;
QCheckBox *randomOffsetX;
......
......@@ -148,7 +148,7 @@ void KisControlFrame::createPatternsChooser(KisViewManager * view)
m_patternsTab->setFont(m_font);
l2->addWidget(m_patternsTab);
m_patternChooser = new KoPatternChooser(m_patternChooserPopup);
m_patternChooser = new KisPatternChooser(m_patternChooserPopup);
m_patternChooser->setFont(m_font);
QWidget *patternChooserPage = new QWidget(m_patternChooserPopup);
QHBoxLayout *patternChooserPageLayout = new QHBoxLayout(patternChooserPage);
......
......@@ -34,7 +34,7 @@ class QPushButton;
class KoAbstractGradient;
class KisGradientChooser;
class KoPatternChooser;
class KisPatternChooser;
class KisPaintopBox;
class KisViewManager;
class KisIconWidget;
......@@ -82,7 +82,7 @@ private:
QWidget *m_gradientChooserPopup;
KisGradientChooser *m_gradientChooser;
KoPatternChooser *m_patternChooser;
KisPatternChooser *m_patternChooser;
KisPaintopBox *m_paintopBox;
......
......@@ -35,7 +35,7 @@
#include "kis_global.h"
#include "KoPattern.h"
KoPatternChooser::KoPatternChooser(QWidget *parent)
KisPatternChooser::KisPatternChooser(QWidget *parent)
: QFrame(parent)
{
m_lbName = new QLabel(this);
......@@ -67,21 +67,21 @@ KoPatternChooser::KoPatternChooser(QWidget *parent)
setLayout(mainLayout);
}
KoPatternChooser::~KoPatternChooser()
KisPatternChooser::~KisPatternChooser()
{
}
KoResource * KoPatternChooser::currentResource()
KoResource * KisPatternChooser::currentResource()
{
return m_itemChooser->currentResource();
}
void KoPatternChooser::setCurrentPattern(KoResource *resource)
void KisPatternChooser::setCurrentPattern(KoResource *resource)
{
m_itemChooser->setCurrentResource(resource);
}
void KoPatternChooser::setCurrentItem(int row, int column)
void KisPatternChooser::setCurrentItem(int row, int column)
{
m_itemChooser->setCurrentItem(row, column);
if (currentResource()) {
......@@ -89,12 +89,12 @@ void KoPatternChooser::setCurrentItem(int row, int column)
}
}
void KoPatternChooser::setPreviewOrientation(Qt::Orientation orientation)
void KisPatternChooser::setPreviewOrientation(Qt::Orientation orientation)
{
m_itemChooser->setPreviewOrientation(orientation);
}
void KoPatternChooser::update(KoResource * resource)
void KisPatternChooser::update(KoResource * resource)
{
KoPattern *pattern = static_cast<KoPattern *>(resource);
......@@ -102,7 +102,7 @@ void KoPatternChooser::update(KoResource * resource)
m_lbName->setText(text);
}
void KoPatternChooser::setGrayscalePreview(bool grayscale)
void KisPatternChooser::setGrayscalePreview(bool grayscale)
{
m_itemChooser->setGrayscalePreview(grayscale);
}
......
......@@ -24,14 +24,14 @@
class QLabel;
class KRITAUI_EXPORT KoPatternChooser : public QFrame
class KRITAUI_EXPORT KisPatternChooser : public QFrame
{
Q_OBJECT
public:
KoPatternChooser(QWidget *parent = 0);
virtual ~KoPatternChooser();
KisPatternChooser(QWidget *parent = 0);
virtual ~KisPatternChooser();
/// Gets the currently selected resource
/// @returns the selected resource, 0 is no resource is selected
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment