[Fix] Fixed the drag&drop crash.

This commit is contained in:
Rtch90 2014-12-18 12:36:41 +00:00
parent 68d4bb443f
commit 33f4a245a7
3 changed files with 4 additions and 1 deletions

View File

@ -6,6 +6,7 @@
PDFPageWidget::PDFPageWidget(QWidget* parent) :
QFrame(parent) {
selected = false;
setAcceptDrops(true);
/* Resize widget. */

View File

@ -46,7 +46,7 @@ private:
QPixmap pixmap;
QPushButton* btn1, *btn2;
bool selected = false;
bool selected;
signals:
void pageClicked(QMouseEvent* event, QString path);

View File

@ -76,6 +76,8 @@ void PDFTableWidget::droppedPage(QString pathFrom, QString pathTo) {
*/
/* Frontend operations here.. */
if(pathFrom == pathTo)
return;
qDebug() << pathFrom;
qDebug() << pathTo;
PDFPageWidget* childFrom = pageChilds[pathFrom];