The branch, master, has been updated.

- Log -----------------------------------------------------------------

commit ea6240b785e02536463e6eb5ac8d63be9e77ba18
Author: Jean-Marc Lasgouttes <lasgout...@lyx.org>
Date:   Thu May 2 19:22:10 2013 +0200

    Even more llvm/clang warnings
    
    Remove lyxview_ member of lyx::Action, fix a prototype in TexStream and 
comment out a Cursor function.

diff --git a/src/Cursor.cpp b/src/Cursor.cpp
index 389a34f..7f8edc2 100644
--- a/src/Cursor.cpp
+++ b/src/Cursor.cpp
@@ -187,7 +187,7 @@ bool bruteFind(Cursor & cursor,
 }
 */
 
-
+/*
 /// moves position closest to (x, y) in given box
 bool bruteFind3(Cursor & cur, int x, int y, bool up)
 {
@@ -249,7 +249,7 @@ bool bruteFind3(Cursor & cur, int x, int y, bool up)
        cur.setCursor(best_cursor);
        return true;
 }
-
+*/
 } // namespace anon
 
 
diff --git a/src/TexStream.cpp b/src/TexStream.cpp
index 3ac285e..dc1c43c 100644
--- a/src/TexStream.cpp
+++ b/src/TexStream.cpp
@@ -34,7 +34,7 @@ public:
        int column() const { return column_; }
 
 protected:
-       int overflow(int);
+       int_type overflow(int_type);
        int sync();
 
 private:
@@ -52,7 +52,7 @@ TexStreamBuffer::TexStreamBuffer(TexStreamBase *sb, TexRow * 
texrow)
        setg(0, 0, 0);
 }
 
-int TexStreamBuffer::overflow(int c)
+TexStreamBuffer::int_type TexStreamBuffer::overflow(TexStreamBuffer::int_type 
c)
 {
        if (c == '\n') {
                ++line_;
diff --git a/src/frontends/qt4/Action.cpp b/src/frontends/qt4/Action.cpp
index 3014e9a..115111f 100644
--- a/src/frontends/qt4/Action.cpp
+++ b/src/frontends/qt4/Action.cpp
@@ -14,7 +14,6 @@
 
 #include "FuncRequest.h"
 #include "FuncStatus.h"
-#include "GuiView.h"
 #include "LyX.h"
 #include "qt_helpers.h"
 
@@ -25,10 +24,10 @@ namespace lyx {
 namespace frontend {
 
 
-Action::Action(GuiView * lyxView, QIcon const & icon,
+Action::Action(QIcon const & icon,
          QString const & text, FuncRequest const & func,
          QString const & tooltip, QObject * parent)
-       : QAction(parent), func_(func), lyxView_(lyxView)
+       : QAction(parent), func_(func)
 {
        // only Qt/Mac handles that
        setMenuRole(NoRole);
diff --git a/src/frontends/qt4/Action.h b/src/frontends/qt4/Action.h
index 11a862b..54954c6 100644
--- a/src/frontends/qt4/Action.h
+++ b/src/frontends/qt4/Action.h
@@ -22,8 +22,6 @@ class FuncRequest;
 
 namespace frontend {
 
-class GuiView;
-
 /**
  * Action - Qt interface with LyX' FuncRequest.
  *
@@ -34,7 +32,7 @@ class Action : public QAction
        Q_OBJECT
 
 public:
-       Action(GuiView * lyxView, QIcon const & icon, QString const & text,
+       Action(QIcon const & icon, QString const & text,
                FuncRequest const & func, QString const & tooltip, QObject * 
parent);
 
        void update();
@@ -48,7 +46,6 @@ private Q_SLOTS:
 
 private:
        FuncRequest const & func_ ;
-       GuiView * lyxView_;
 };
 
 
diff --git a/src/frontends/qt4/GuiToolbar.cpp b/src/frontends/qt4/GuiToolbar.cpp
index f41fd2c..b459c60 100644
--- a/src/frontends/qt4/GuiToolbar.cpp
+++ b/src/frontends/qt4/GuiToolbar.cpp
@@ -102,8 +102,8 @@ Action * GuiToolbar::addItem(ToolbarItem const & item)
        if (!bindings.empty())
                text += " [" + 
toqstr(bindings.begin()->print(KeySequence::ForGui)) + "]";
 
-       Action * act = new Action(&owner_, getIcon(item.func_, false),
-               text, item.func_, text, this);
+       Action * act = new Action(getIcon(item.func_, false),
+                                 text, item.func_, text, this);
        actions_.append(act);
        return act;
 }
diff --git a/src/frontends/qt4/Menus.cpp b/src/frontends/qt4/Menus.cpp
index 06128d8..652bce1 100644
--- a/src/frontends/qt4/Menus.cpp
+++ b/src/frontends/qt4/Menus.cpp
@@ -1719,7 +1719,7 @@ void Menu::Impl::populate(QMenu & qMenu, MenuDefinition 
const & menu)
                        subMenu->setEnabled(m->status().enabled());
                } else {
                        // we have a MenuItem::Command
-                       qMenu.addAction(new Action(view, QIcon(), label(*m),
+                       qMenu.addAction(new Action(QIcon(), label(*m),
                                m->func(), m->tooltip(), &qMenu));
                }
        }
@@ -1806,7 +1806,7 @@ struct Menus::Impl {
                BufferView const *) const;
 
        /// Initialize specific MACOS X menubar
-       void macxMenuBarInit(GuiView * view, QMenuBar * qmb);
+       void macxMenuBarInit(QMenuBar * qmb);
 
        /// Mac special menu.
        /** This defines a menu whose entries list the FuncRequests
@@ -1856,7 +1856,7 @@ MenuDefinition Menus::Impl::mac_special_menu_;
   that this menubar will be used also when one of LyX' dialogs has
   focus. (JMarc)
 */
-void Menus::Impl::macxMenuBarInit(GuiView * view, QMenuBar * qmb)
+void Menus::Impl::macxMenuBarInit(QMenuBar * qmb)
 {
        /* Since Qt 4.2, the qt/mac menu code has special code for
           specifying the role of a menu entry. However, it does not
@@ -1909,13 +1909,13 @@ void Menus::Impl::macxMenuBarInit(GuiView * view, 
QMenuBar * qmb)
        for (size_t i = 0 ; cit != end ; ++cit, ++i) {
 #if defined(QT_MAC_USE_COCOA) && (QT_MAC_USE_COCOA > 0)
                if (first_call || entries[i].role != 
QAction::ApplicationSpecificRole) {
-                       Action * action = new Action(view, QIcon(), 
cit->label(),
+                       Action * action = new Action(QIcon(), cit->label(),
                                 cit->func(), QString(), qMenu);
                        action->setMenuRole(entries[i].role);
                        qMenu->addAction(action);
                }
 #else
-               Action * action = new Action(view, QIcon(), cit->label(),
+               Action * action = new Action(QIcon(), cit->label(),
                        cit->func(), QString(), qMenu);
                action->setMenuRole(entries[i].role);
                qMenu->addAction(action);
@@ -2189,7 +2189,7 @@ void Menus::fillMenuBar(QMenuBar * qmb, GuiView * view, 
bool initial)
                // create duplicate items in the application menu. It seems
                // that Qt does not remove them when the QMenubar is cleared.
                LYXERR(Debug::GUI, "Creating Mac OS X special menu bar");
-               d->macxMenuBarInit(view, qmb);
+               d->macxMenuBarInit(qmb);
 #endif
        } else {
                // Clear all menubar contents before filling it.

-----------------------------------------------------------------------

Summary of changes:
 src/Cursor.cpp                   |    4 ++--
 src/TexStream.cpp                |    4 ++--
 src/frontends/qt4/Action.cpp     |    5 ++---
 src/frontends/qt4/Action.h       |    5 +----
 src/frontends/qt4/GuiToolbar.cpp |    4 ++--
 src/frontends/qt4/Menus.cpp      |   12 ++++++------
 6 files changed, 15 insertions(+), 19 deletions(-)


hooks/post-receive
-- 
The LyX Source Repository

Reply via email to