diff -r b78b6cf02213 -r 99085cfaeabd src/guiutilities.cpp --- a/src/guiutilities.cpp Sun Mar 05 20:26:56 2017 +0200 +++ b/src/guiutilities.cpp Mon Mar 06 00:35:47 2017 +0200 @@ -23,10 +23,6 @@ #include "lddocument.h" #include "mainwindow.h" -GuiUtilities::GuiUtilities (QObject* parent) : - QObject (parent), - HierarchyElement (parent) {} - /* * makeColorIcon * @@ -63,11 +59,11 @@ * * Fills the provided combo box with the colors used in the current document. */ -void GuiUtilities::fillUsedColorsToComboBox (QComboBox* box) +void GuiUtilities::fillUsedColorsToComboBox(Model* model, QComboBox* box) { QMap frequencies; - for (LDObject* object : currentDocument()->objects()) + for (LDObject* object : model->objects()) { if (object->isColored() and object->color().isValid()) {