Changeset 11055


Ignore:
Timestamp:
Jul 25, 2010, 8:38:44 PM (12 years ago)
Author:
charles
Message:

(trunk qt) if the server doesn't have a favicon, don't keep retrying for one

Location:
trunk/qt
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/qt/favicon.cc

    r11053 r11055  
    9494
    9595    const QString host = getHost( url );
    96     if( !myPixmaps.contains( host ) && !myPending.contains( host ) )
     96
     97    if( !myPixmaps.contains( host ) )
    9798    {
    98         myPending.append( host );
     99        // add a placholder s.t. we only ping the server once per session
     100        myPixmaps.insert( host, QPixmap( ) );
    99101
     102        // try to download the favicon
    100103        const QString path = "http://" + host + "/favicon.";
    101104        QStringList suffixes;
     
    110113{
    111114    const QString host = reply->url().host();
    112     myPending.removeAll( host );
    113115
    114116    QPixmap pixmap;
  • trunk/qt/favicon.h

    r11053 r11055  
    2020#include <QMap>
    2121#include <QString>
    22 #include <QStringList>
    2322#include <QObject>
    2423#include <QPixmap>
     
    4544    private:
    4645
    47         QStringList myPending;
    4846        QNetworkAccessManager * myNAM;
    4947        QMap<QString,QPixmap> myPixmaps;
Note: See TracChangeset for help on using the changeset viewer.