Skip to content

Commit

Permalink
GUI: Move some public members functions into private
Browse files Browse the repository at this point in the history
  • Loading branch information
fdde authored and DrMcCoy committed Dec 29, 2017
1 parent 8596094 commit 3de76c2
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 12 deletions.
11 changes: 6 additions & 5 deletions src/gui/panelpreviewimage.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,6 @@ class PanelPreviewImage : public QFrame {

Qt::TransformationMode _mode;

public:
PanelPreviewImage(QWidget *parent = 0);

void setItem(const GUI::ResourceTreeItem *item);
void loadImage();
void convertImage(const Images::Decoder &image, byte *data, QImage::Format &format);
void writePixel(const byte *&data, Images::PixelFormat format, byte *&data_out, QImage::Format &format_out);
Expand All @@ -92,7 +88,12 @@ class PanelPreviewImage : public QFrame {
void zoomStep(float step);
void updateButtons();

/*slots:*/
public:
PanelPreviewImage(QWidget *parent = 0);

void setItem(const GUI::ResourceTreeItem *item);

// public slots:
void slotSliderBrightness(int value);
void slotZoomIn();
void slotZoomOut();
Expand Down
13 changes: 7 additions & 6 deletions src/gui/panelpreviewsound.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,8 @@ class PanelPreviewSound : public QFrame {
uint64 _duration;
QTimer *_timer;

public:
PanelPreviewSound(QWidget *parent = 0);

void setItem(const ResourceTreeItem *item);

bool play();
void pause();
void stop();
void changeVolume(int value);
void positionChanged(qint64 position);

Expand All @@ -81,6 +75,13 @@ class PanelPreviewSound : public QFrame {
int getSliderPos(uint64 total, uint64 t) const;
void setButtons(bool enablePlay, bool enablePause, bool enableStop);
void update();

public:
PanelPreviewSound(QWidget *parent = 0);

void setItem(const ResourceTreeItem *item);

void stop();
};

} // End of namespace GUI
Expand Down
4 changes: 3 additions & 1 deletion src/gui/panelpreviewtext.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,14 @@ class PanelPreviewText : public QFrame {

const ResourceTreeItem *_currentItem;

void setText(const QString &text);

public:
PanelPreviewText(QWidget *parent = 0);

void setText(const QString &text);
void setItem(const ResourceTreeItem *item);

// public signals:
void log(const QString &text)
W_SIGNAL(log, text)
};
Expand Down

0 comments on commit 3de76c2

Please sign in to comment.