mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-10-18 08:31:16 +02:00
2020-05-17 Fred Gleason <fredg@paravelsystems.com>
* Added a 'FEEDS.CHANNEL_IMAGE_ID' field to the database. * Added a 'FEEDS.DEFAULT_ITEM_IMAGE_ID' field to the database. * Added a 'PODCASTS.ITEM_IMAGE_ID' field to the database. * Incremented the database version to 324. * Added an 'Image Manager' dialog to rdadmin(1). * Added an 'Image Viewer' dialog on rdadmin(1). Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
66
rdadmin/edit_image.h
Normal file
66
rdadmin/edit_image.h
Normal file
@@ -0,0 +1,66 @@
|
||||
// edit_image.h
|
||||
//
|
||||
// View a pixmap image and modify its metadata
|
||||
//
|
||||
// (C) Copyright 2020 Fred Gleason <fredg@paravelsystems.com>
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License version 2 as
|
||||
// published by the Free Software Foundation.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public
|
||||
// License along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
//
|
||||
|
||||
#ifndef EDIT_IMAGE_H
|
||||
#define EDIT_IMAGE_H
|
||||
|
||||
#include <qimage.h>
|
||||
#include <qlabel.h>
|
||||
#include <qlineedit.h>
|
||||
#include <qpushbutton.h>
|
||||
|
||||
#include <rddialog.h>
|
||||
|
||||
#define EDIT_IMAGE_WIDTH_OFFSET 20
|
||||
#define EDIT_IMAGE_HEIGHT_OFFSET 95
|
||||
|
||||
class EditImage : public RDDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
EditImage(QWidget *parent=0);
|
||||
~EditImage();
|
||||
QSize sizeHint() const;
|
||||
|
||||
public slots:
|
||||
int exec(int img_id);
|
||||
|
||||
private slots:
|
||||
void okData();
|
||||
void cancelData();
|
||||
|
||||
protected:
|
||||
void closeEvent(QCloseEvent *e);
|
||||
void resizeEvent(QResizeEvent *e);
|
||||
|
||||
private:
|
||||
QSize FittedSize(const QSize &img_size) const;
|
||||
QSize MaxFriendlyImageSize() const;
|
||||
QLabel *c_image_label;
|
||||
QLabel *c_description_label;
|
||||
QLineEdit *c_description_edit;
|
||||
QPushButton *c_ok_button;
|
||||
QPushButton *c_cancel_button;
|
||||
QImage c_image;
|
||||
int c_image_id;
|
||||
};
|
||||
|
||||
|
||||
#endif // EDIT_IMAGE_H
|
Reference in New Issue
Block a user