diff options
Diffstat (limited to 'src/dragdrop.h')
-rw-r--r-- | src/dragdrop.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/dragdrop.h b/src/dragdrop.h index ef4c2b844..97f978ee2 100644 --- a/src/dragdrop.h +++ b/src/dragdrop.h @@ -68,6 +68,9 @@ class DragDrop final ItemColor getItemColor() const { return mItemColor; } + void setItemColor(const ItemColor color) + { mItemColor = color; } + Image *getItemImage() { return mItemImage; } @@ -144,7 +147,7 @@ class DragDrop final if (mItemImage) mItemImage->decRef(); mItem = 0; - mItemColor = ItemColor_one; + mItemColor = ItemColor_zero; mText.clear(); mItemImage = nullptr; mSource = DragDropSource::Empty; @@ -158,10 +161,12 @@ class DragDrop final mItemImage = data->icon; if (mItemImage) mItemImage->incRef(); - mItem = info->id; mSource = source; mTag = tag; } + mItem = info->id; + mItemColor = fromInt(info->selectedLevel, + ItemColor); } } |