#include "DownloadDevice.h"
#include <nsArrayUtils.h>
#include <nsAutoLock.h>
#include <nsComponentManagerUtils.h>
#include <nsCRT.h>
#include <nsIDOMWindow.h>
#include <nsILocalFile.h>
#include <nsINetUtil.h>
#include <nsIProperties.h>
#include <nsIStandardURL.h>
#include <nsIFileURL.h>
#include <nsISupportsPrimitives.h>
#include <nsITreeView.h>
#include <nsIURL.h>
#include <nsIUTF8ConverterService.h>
#include <nsIWindowWatcher.h>
#include <nsIResumableChannel.h>
#include <nsServiceManagerUtils.h>
#include <nsNetUtil.h>
#include <nsUnicharUtils.h>
#include <prmem.h>
#include <sbILibraryManager.h>
#include <sbILocalDatabaseLibrary.h>
#include <sbIFileMetadataService.h>
#include <sbIJobProgress.h>
#include <sbIPropertyManager.h>
#include <sbStandardProperties.h>
#include <nsIChannel.h>
#include <prprf.h>
Go to the source code of this file.
|
static PRInt32 | codetovalue (unsigned char c) |
|
static PRStatus | decode4to3 (const unsigned char *src, unsigned char *dest) |
|
static PRStatus | decode3to2 (const unsigned char *src, unsigned char *dest) |
|
static PRStatus | decode2to1 (const unsigned char *src, unsigned char *dest) |
|
static PRStatus | decode (const unsigned char *src, PRUint32 srclen, unsigned char *dest) |
|
char * | SB_Base64Decode (const char *src, PRUint32 srclen, char *dest) |
|
nsCString | GetContentDispositionFilename (const nsACString &contentDisposition) |
|
| NS_IMPL_ISUPPORTS4 (sbDownloadDevice, nsIObserver, sbIDeviceBase, sbIDownloadDevice, sbIMediaListListener) sbDownloadDevice |
|
| NS_IMPL_THREADSAFE_ISUPPORTS2 (sbDownloadSession, nsIWebProgressListener, nsITimerCallback) NS_IMETHODIMP sbDownloadSession |
|
| NS_IMPL_ISUPPORTS1 (sbDownloadSession::LibraryMetadataUpdater, sbIMediaListEnumerationListener) NS_IMETHODIMP sbDownloadSession |
| Called when enumeration is about to begin. More...
|
|
| NS_IMPL_ISUPPORTS1 (sbDownloadSession::WebLibraryUpdater, sbIMediaListEnumerationListener) NS_IMETHODIMP sbDownloadSession |
| Called when enumeration is about to begin. More...
|
|
| NS_IMPL_THREADSAFE_ISUPPORTS1 (sbDownloadSessionMoveHandler, nsIRunnable) NS_IMETHODIMP sbDownloadSessionMoveHandler |
|
#define LOG |
( |
|
args | ) |
/* nothing */ |
#define SB_DOWNLOAD_COL_SPEC "http://songbirdnest.com/data/1.0#trackName 179 http://songbirdnest.com/data/1.0#artistName 115 http://songbirdnest.com/data/1.0#albumName 115 http://songbirdnest.com/data/1.0#originPageImage 43 http://songbirdnest.com/data/1.0#downloadDetails 266 http://songbirdnest.com/data/1.0#downloadButton 73" |
#define SB_DOWNLOAD_CUSTOM_TYPE "download" |
#define SB_DOWNLOAD_DEVICE_CATEGORY NS_LITERAL_STRING("Songbird Download Device").get() |
#define SB_DOWNLOAD_DEVICE_ID "download" |
#define SB_DOWNLOAD_DIR_DR "download.folder" |
#define SB_DOWNLOAD_IDLE_TIMEOUT_MS (60*1000) |
#define SB_DOWNLOAD_LIST_NAME "&chrome://songbird/locale/songbird.properties#device.download" |
#define SB_DOWNLOAD_PROGRESS_TIMER_MS 1000 |
#define SB_DOWNLOAD_PROGRESS_UPDATE_PERIOD_MS 1000 |
#define SB_DOWNLOAD_TMP_DIR "DownloadDevice" |
#define SB_PREF_DOWNLOAD_MEDIALIST "songbird.library.download" |
#define SB_PREF_WEB_LIBRARY "songbird.library.web" |
#define SB_STRING_BUNDLE_CHROME_URL "chrome://songbird/locale/songbird.properties" |
#define SB_TMP_DIR "Songbird" |
#define TRACE |
( |
|
args | ) |
/* nothing */ |
static PRInt32 codetovalue |
( |
unsigned char |
c | ) |
|
|
static |
static PRStatus decode |
( |
const unsigned char * |
src, |
|
|
PRUint32 |
srclen, |
|
|
unsigned char * |
dest |
|
) |
| |
|
static |
static PRStatus decode2to1 |
( |
const unsigned char * |
src, |
|
|
unsigned char * |
dest |
|
) |
| |
|
static |
static PRStatus decode3to2 |
( |
const unsigned char * |
src, |
|
|
unsigned char * |
dest |
|
) |
| |
|
static |
static PRStatus decode4to3 |
( |
const unsigned char * |
src, |
|
|
unsigned char * |
dest |
|
) |
| |
|
static |
nsCString GetContentDispositionFilename |
( |
const nsACString & |
contentDisposition | ) |
|
Called when enumeration is about to begin.
- Parameters
-
aMediaList | - The media list that is being enumerated. |
- Returns
- true to begin enumeration, false to cancel.
Definition at line 4073 of file DownloadDevice.cpp.
Called when enumeration is about to begin.
- Parameters
-
aMediaList | - The media list that is being enumerated. |
- Returns
- true to begin enumeration, false to cancel.
Definition at line 4176 of file DownloadDevice.cpp.
Notification indicating the state has changed for one of the requests associated with aWebProgress.
- Parameters
-
aWebProgress | The nsIWebProgress instance that fired the notification |
aRequest | The nsIRequest that has changed state. |
aStateFlags | Flags indicating the new state. This value is a combination of one of the State Transition Flags and one or more of the State Type Flags defined above. Any undefined bits are reserved for future use. |
aStatus | Error status code associated with the state change. This parameter should be ignored unless aStateFlags includes the STATE_STOP bit. The status code indicates success or failure of the request associated with the state change. NOTE: aStatus may be a success code even for server generated errors, such as the HTTP 404 error. In such cases, the request itself should be queried for extended error information (e.g., for HTTP requests see nsIHttpChannel). |
Definition at line 3051 of file DownloadDevice.cpp.
char* SB_Base64Decode |
( |
const char * |
src, |
|
|
PRUint32 |
srclen, |
|
|
char * |
dest |
|
) |
| |