From: Manuel Nickschas Date: Wed, 27 Jun 2007 22:24:56 +0000 (+0000) Subject: Fixed a problem where cmake apparently didn't get all deps right and screwed up by... X-Git-Tag: 0.1.0~187 X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=commitdiff_plain;h=9a39bcb0e71d45140dc7f2390536cf4f7e13e9fe;ds=sidebyside Fixed a problem where cmake apparently didn't get all deps right and screwed up by linking qtgui. Removed previous fugly workaround. Also got rid of the warnings in buffertreemodel.cpp, while I was at it. --- diff --git a/src/client/buffertreemodel.cpp b/src/client/buffertreemodel.cpp index 3aac9f31..741215f0 100644 --- a/src/client/buffertreemodel.cpp +++ b/src/client/buffertreemodel.cpp @@ -46,7 +46,7 @@ QString BufferTreeItem::text(int column) const { } } -QColor BufferTreeItem::foreground(int column) const { +QColor BufferTreeItem::foreground(int /*column*/) const { // for the time beeing we ignore the column :) if(activity & Buffer::Highlight) { return QColor(Qt::red); @@ -182,7 +182,7 @@ QMimeData *BufferTreeModel::mimeData(const QModelIndexList &indexes) const { return mimeData; } -bool BufferTreeModel::dropMimeData(const QMimeData *data, Qt::DropAction action, int row, int column, const QModelIndex &parent) { +bool BufferTreeModel::dropMimeData(const QMimeData *data, Qt::DropAction /*action*/, int /*row*/, int /*column*/, const QModelIndex &parent) { if(!(data->hasFormat("application/Quassel/BufferItem/row") && data->hasFormat("application/Quassel/BufferItem/network") && data->hasFormat("application/Quassel/BufferItem/bufferId"))) @@ -227,7 +227,7 @@ void BufferTreeModel::bufferUpdated(Buffer *buffer) { } // This Slot indicates that the user has selected a different buffer in the gui -void BufferTreeModel::changeCurrent(const QModelIndex ¤t, const QModelIndex &previous) { +void BufferTreeModel::changeCurrent(const QModelIndex ¤t, const QModelIndex &/*previous*/) { if(isBufferIndex(current)) { currentBuffer = getBufferByIndex(current); bufferActivity(Buffer::NoActivity, currentBuffer); diff --git a/src/common/main.cpp b/src/common/main.cpp index a35ab4cb..51de3c46 100644 --- a/src/common/main.cpp +++ b/src/common/main.cpp @@ -74,8 +74,6 @@ int main(int argc, char **argv) { #ifndef BUILD_CORE Style::init(); - AbstractUi foo; // This avoids an annoying linker error (bug?) where AbstractUi's vtable is not found. - // Yes, it's fugly. Yes, I'd like an alternative. QtGui *gui = new QtGui(); Client::init(gui); gui->init(); diff --git a/src/common/quasselui.h b/src/common/quasselui.h index 0925b2ee..2b31170f 100644 --- a/src/common/quasselui.h +++ b/src/common/quasselui.h @@ -41,10 +41,9 @@ class AbstractUi : public QObject { Q_OBJECT public: - static void foo() {}; - virtual ~AbstractUi() {}; +// virtual ~AbstractUi() {}; virtual void init() {}; // called after the client is initialized - virtual AbstractUiMsg *layoutMsg(const Message &) { return 0; } + virtual AbstractUiMsg *layoutMsg(const Message &) = 0; protected slots: virtual void connectedToCore() {} diff --git a/src/qtgui/CMakeLists.txt b/src/qtgui/CMakeLists.txt index 11985659..82ad6ff8 100644 --- a/src/qtgui/CMakeLists.txt +++ b/src/qtgui/CMakeLists.txt @@ -22,3 +22,4 @@ QT4_WRAP_CPP(_MOC ${qtgui_MOCS}) INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}) ADD_LIBRARY(qtgui ${qtgui_HDRS} ${qtgui_SRCS} ${_MOC} ${_UIC}) +TARGET_LINK_LIBRARIES(qtgui common) \ No newline at end of file