Ignore:
Timestamp:
May 23, 2013, 5:06:17 PM (13 years ago)
Author:
Silvan Scherrer
Message:

SMPlayer: update vendor to 0.8.5'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • smplayer/vendor/current/src/core.cpp

    r137 r140  
    11/*  smplayer, GUI front-end for mplayer.
    2     Copyright (C) 2006-2012 Ricardo Villalba <[email protected]>
     2    Copyright (C) 2006-201 Ricardo Villalba <[email protected]>
    33
    44    This program is free software; you can redistribute it and/or modify
     
    130130                         this, SLOT(displayMessage(QString)) );
    131131
     132
     133
     134
     135
     136
     137
     138
     139
    132140        connect( proc, SIGNAL(receivedCreatingIndex(QString)),
    133141                         this, SLOT(displayMessage(QString)) );
    134142
     143
     144
     145
    135146        connect( proc, SIGNAL(receivedConnectingToMessage(QString)),
    136147                         this, SLOT(displayMessage(QString)) );
    137148
     149
     150
     151
    138152        connect( proc, SIGNAL(receivedResolvingMessage(QString)),
    139153                         this, SLOT(displayMessage(QString)) );
    140154
     155
     156
     157
    141158        connect( proc, SIGNAL(receivedScreenshot(QString)),
    142159             this, SLOT(displayScreenshotName(QString)) );
     
    144161        connect( proc, SIGNAL(receivedUpdatingFontCache()),
    145162             this, SLOT(displayUpdatingFontCache()) );
    146        
     163
    147164        connect( proc, SIGNAL(receivedScanningFont(QString)),
    148165                         this, SLOT(displayMessage(QString)) );
    149        
     166
    150167        connect( proc, SIGNAL(receivedWindowResolution(int,int)),
    151168             this, SLOT(gotWindowResolution(int,int)) );
     
    252269        connect(yt, SIGNAL(gotEmptyList()), this, SLOT(YTNoVideoUrl()));
    253270#endif
     271
     272
    254273}
    255274
     
    521540
    522541                QFileInfo fi(sub);
    523                 if ((pref->fast_load_sub) && (fi.suffix().toLower() != "idx")) {
     542                if ((pref->fast_load_sub) && (fi.suffix().toLower() != "idx")) {
    524543                        QString sub_file = sub;
    525544                        #ifdef Q_OS_WIN
     
    11521171                qDebug("Core::stop: mset.current_sec set to 0");
    11531172                emit showTime( mset.current_sec );
    1154 #ifdef SEEKBAR_RESOLUTION
     1173#ifdef SEEKBAR_RESOLUTION
    11551174                emit positionChanged( 0 );
    1156 #else
     1175#else
    11571176                emit posChanged( 0 );
    1158 #endif
     1177#endif
    11591178                //updateWidgets();
    11601179        }
     
    11621181        stopMplayer();
    11631182        emit mediaStoppedByUser();
     1183
     1184
     1185
     1186
     1187
     1188
     1189
     1190
     1191
     1192
    11641193}
    11651194
     
    14081437    if (fi.exists() && fi.isExecutable() && !fi.isDir()) {
    14091438        mplayer_bin = fi.absoluteFilePath();
     1439
     1440
     1441
     1442
     1443
     1444
     1445
    14101446        }
    14111447
     
    17071743#if !defined(Q_OS_OS2)
    17081744                if (!pref->ass_styles.fontname.isEmpty()) {
     1745
    17091746                        if (!pref->mplayer_is_mplayer2) { // -fontconfig removed from mplayer2
    17101747                                proc->addArgument("-fontconfig");
    17111748                        }
     1749
    17121750                        proc->addArgument("-font");
    17131751                        proc->addArgument( pref->ass_styles.fontname );
     
    17181756                        proc->addArgument("-subfont-autoscale");
    17191757                        proc->addArgument("0");
    1720                         proc->addArgument("-subfont-osd-scale");
    1721                         proc->addArgument(QString::number(pref->ass_styles.fontsize));
     1758                        if (!pref->mplayer_is_mplayer2) { // Prevent huge OSD in mplayer2
     1759                                proc->addArgument("-subfont-osd-scale");
     1760                                proc->addArgument(QString::number(pref->ass_styles.fontsize));
     1761                        }
    17221762                        proc->addArgument("-subfont-text-scale"); // Old versions (like 1.0rc2) need this
    17231763                        proc->addArgument(QString::number(pref->ass_styles.fontsize));
     
    17281768#if !defined(Q_OS_OS2)
    17291769                if ( (pref->use_fontconfig) && (!pref->font_name.isEmpty()) ) {
     1770
    17301771                        if (!pref->mplayer_is_mplayer2) { // -fontconfig removed from mplayer2
    17311772                                proc->addArgument("-fontconfig");
    17321773                        }
     1774
    17331775                        proc->addArgument("-font");
    17341776                        proc->addArgument( pref->font_name );
     
    17361778#endif
    17371779                if ( (!pref->use_fontconfig) && (!pref->font_file.isEmpty()) ) {
     1780
     1781
     1782
     1783
     1784
    17381785                        proc->addArgument("-font");
    17391786                        proc->addArgument( pref->font_file );
     
    18381885                        #endif
    18391886                        proc->addArgument( mset.external_subtitles );
     1887
     1888
     1889
     1890
     1891
     1892
     1893
     1894
     1895
     1896
     1897
     1898
     1899
     1900
    18401901                }
    18411902        }
     
    22042265        // Stereo mode
    22052266        if (mset.stereo_mode != 0) {
    2206                 if (mset.stereo_mode == MediaSettings::Left)
    2207                         af += "channels=2:2:0:1:0:0";
    2208                 else
    2209                         af += "channels=2:2:1:0:1:1";
     2267                switch (mset.stereo_mode) {
     2268                        case MediaSettings::Left: af += "channels=2:2:0:1:0:0"; break;
     2269                        case MediaSettings::Right: af += "channels=2:2:1:0:1:1"; break;
     2270                        case MediaSettings::Mono: af += "pan=1:0.5:0.5"; break;
     2271                        case MediaSettings::Reverse: af += "channels=2:2:0:1:1:0"; break;
     2272                }
    22102273        }
    22112274
     
    30993162        else
    31003163                displayMessage( tr("Subtitles off") );
     3164
     3165
     3166
     3167
     3168
     3169
     3170
     3171
    31013172}
    31023173
     
    36803751#endif
    36813752
     3753
    36823754void Core::changeSize(int n) {
    36833755        if ( /*(n != pref->size_factor) &&*/ (!pref->use_mplayer_window) ) {
     
    36953767                changeSize(200);
    36963768}
     3769
    36973770
    36983771void Core::changeZoom(double p) {
     
    39464019        qDebug("Core::displayUpdatingFontCache");
    39474020        emit showMessage( tr("Updating the font cache. This may take some seconds...") );
     4021
     4022
     4023
     4024
    39484025}
    39494026
Note: See TracChangeset for help on using the changeset viewer.