Ticket #46748: patch-vlc-qt4mac.diff

File patch-vlc-qt4mac.diff, 2.3 KB (added by RJVB (René Bertin), 10 years ago)
  • modules/gui/qt4/util/searchlineedit.cpp

    diff --git modules/gui/qt4/util/searchlineedit.cpp modules/gui/qt4/util/searchlineedit.cpp
    index 94744ec..e83625d 100644
    void ClickLineEdit::focusOutEvent( QFocusEvent *ev ) 
    103103}
    104104#endif
    105105
    106 #ifndef Q_OS_MAC
     106#ifndef Q_OS_MAC_UNUSED
    107107SearchLineEdit::SearchLineEdit( QWidget *parent ) : QLineEdit( parent )
    108108{
    109109    clearButton = new QFramelessButton( this );
    void SearchLineEdit::searchEditingFinished() 
    202202    emit searchDelayedChanged( text() );
    203203}
    204204
     205// #else
     206//
     207// void SearchLineEdit::updateText( const QString& text )
     208// {
     209// }
     210//
     211// void SearchLineEdit::searchEditingFinished()
     212// {
     213// }
     214
    205215#endif
  • modules/gui/qt4/util/searchlineedit.hpp

    diff --git modules/gui/qt4/util/searchlineedit.hpp modules/gui/qt4/util/searchlineedit.hpp
    index a09b9bc..8d9e2b7 100644
    private: 
    7272};
    7373#endif
    7474
    75 #ifndef Q_OS_MAC
     75#ifndef Q_OS_MAC_UNUSED
    7676class QFramelessButton;
    7777class SearchLineEdit : public QLineEdit
    7878{
    private slots: 
    9999signals:
    100100    void searchDelayedChanged( const QString& );
    101101};
    102 #else
    103 
    104 /* On Mac, we try to use the native NSSearchField */
    105 #include <QMacCocoaViewContainer>
    106 
    107 class SearchLineEdit : public QMacCocoaViewContainer
    108 {
    109     Q_OBJECT
    110 
    111 public:
    112     SearchLineEdit(QWidget *parent = 0);
    113     virtual ~SearchLineEdit() {}
    114 
    115     virtual QSize sizeHint() const { return QSize(150, 40); }
    116 
    117 public slots:
    118     void clear() {}
    119 
    120 signals:
    121     void searchDelayedChanged( const QString& );
    122     void textEdited( const QString& );
    123 };
     102// #else
     103//
     104// /* On Mac, we try to use the native NSSearchField */
     105// #include <QMacCocoaViewContainer>
     106//
     107// class SearchLineEdit : public QMacCocoaViewContainer
     108// {
     109//     Q_OBJECT
     110//
     111// public:
     112//     SearchLineEdit(QWidget *parent = 0);
     113//     virtual ~SearchLineEdit() {}
     114//
     115//     virtual QSize sizeHint() const { return QSize(150, 40); }
     116//
     117// public slots:
     118//     void clear() {}
     119//
     120// // moc does not look at #ifdefs, so we must provide the same slots and signals
     121// private slots:
     122//     void updateText( const QString& );
     123//     void searchEditingFinished();
     124//
     125// signals:
     126//     void searchDelayedChanged( const QString& );
     127//     void textEdited( const QString& );
     128// };
    124129#endif
    125130
    126131#endif