Get rid of win32 code

This commit is contained in:
Julien BLACHE 2009-04-01 14:48:27 +02:00
parent e747ba2e1d
commit 180cc2eb5a
127 changed files with 2 additions and 11487 deletions

View File

@ -80,6 +80,5 @@ EXTRA_DIST = rend-howl.c rend-posix.c rend-osx.c scan-mpc.c \
scan-ogg.c scan-flac.c db-sql.c db-sql.h \
db-sql-sqlite2.h db-sql-sqlite2.c \
db-sql-sqlite3.h db-sql-sqlite3.c \
w32-eventlog.c w32-eventlog.h w32-service.c w32-service.h \
os-win32.h os-win32.c win32.h db-gdbm.c db-gdbm.h \
db-gdbm.c db-gdbm.h \
ff-plugins.h ff-dbstruct.h upnp.c upnp.h ff-plugin-events.h

View File

@ -1,581 +0,0 @@
/* $Id$
*
*/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <pthread.h>
#include <sys/types.h>
#include <sys/stat.h>
#include "daapd.h"
#include "win32.h"
#include "err.h"
#include "os-win32.h"
#include "plugin.h"
#include "w32-eventlog.h"
#include "w32-service.h"
#include "util.h"
/* Globals */
static WSADATA w32_wsadata;
static os_serviceflag = 0;
static pthread_t os_service_tid;
static os_initialized=0;
static pthread_mutex_t os_mutex=PTHREAD_MUTEX_INITIALIZER;
static char *os_drive_maps[26];
static int os_maps_init=0;
/* Forwards */
static void _os_socket_startup(void);
static void _os_socket_shutdown(void);
static void _os_lock(void);
static void _os_unlock(void);
static BOOL WINAPI _os_cancelhandler(DWORD dwCtrlType);
char *_os_filepath(char *file);
extern int gettimeout(struct timeval end,struct timeval *timeoutp);
/* Globals */
char os_config_file[PATH_MAX];
/* "official" os interface functions */
/**
* initialize the os-specific stuff. this would include
* backgrounding (or starting as service), setting up
* signal handlers (or ctrl-c handlers), etc
*
* @param background whether or not to start in background (service)
* @param runas we'll ignore this, as it's a unix thang
* @returns TRUE on success, FALSE otherwise
*/
int os_init(int foreground, char *runas) {
int err;
char *inifile;
char drive_buffer[4];
char drive_map[PATH_MAX];
int drive_letter;
inifile=_os_filepath("mapping.ini");
DPRINTF(E_LOG,L_MISC,"Building drive mapping table from %s\n",inifile);
for(drive_letter = 'a'; drive_letter <= 'z'; drive_letter++) {
sprintf(drive_buffer,"%c",drive_letter);
GetPrivateProfileString("mapping",drive_buffer,"",drive_map,PATH_MAX,inifile);
if(strlen(drive_map)) {
os_drive_maps[drive_letter - 'a'] = strdup(drive_map);
DPRINTF(E_LOG,L_MISC,"Mapped %c to %s\n",drive_letter,drive_map);
} else {
os_drive_maps[drive_letter - 'a'] = NULL;
}
}
os_maps_init=1;
free(inifile);
if(!foreground) {
/* startup as service */
os_serviceflag = 1;
if((err=pthread_create(&os_service_tid,NULL,service_startup,NULL))) {
DPRINTF(E_LOG,L_MISC,"Could not spawn thread: %s\n",strerror(err));
return FALSE;
}
} else {
/* let's set a ctrl-c handler! */
SetConsoleCtrlHandler(_os_cancelhandler,TRUE);
}
return TRUE;
}
/**
* wait for signals
*
* don't care about signals on win32, so we'll just sleep
*/
void os_wait(int seconds) {
Sleep(seconds * 1000);
}
/**
* shutdown the system-specific stuff started in os_init.
*/
void os_deinit(void) {
if(os_serviceflag) {
/* then we need to stop the service */
SetConsoleCtrlHandler(_os_cancelhandler,FALSE);
service_shutdown(0);
}
}
/**
* open the syslog (eventlog)
*/
int os_opensyslog(void) {
elog_register();
return elog_init();
}
/**
* close the syslog (eventlog)
*/
int os_closesyslog(void) {
return elog_deinit();
}
/**
* write a message to the syslog
*
* @param level what level of message (1-10)
* @param msg message to write
* @return TRUE on success, FALSE otherwise
*/
int os_syslog(int level, char *msg) {
return elog_message(level, msg);
}
/**
* change the owner of a file to a specific user. This is
* ignored on windows
*/
extern int os_chown(char *path, char *user) {
return TRUE;
}
int os_signal_server(int what) {
/* this could really control the service somehow */
fprintf(stderr,"This function is unimplemented on win32\n");
exit(-1);
}
int os_register(void) {
service_register();
elog_register();
return TRUE;
}
int os_unregister(void) {
service_unregister();
elog_unregister();
return TRUE;
}
static BOOL WINAPI _os_cancelhandler(DWORD dwCtrlType) {
DPRINTF(E_LOG,L_MISC,"Shutting down with a console event\n");
config.stop = 1;
return TRUE;
}
/* from the gnu c library */
char *os_strsep(char **stringp, const char *delim) {
char *begin, *end;
begin = *stringp;
if (begin == NULL)
return NULL;
/* A frequent case is when the delimiter string contains only one
character. Here we don't need to call the expensive `strpbrk'
function and instead work using `strchr'. */
if (delim[0] == '\0' || delim[1] == '\0') {
char ch = delim[0];
if (ch == '\0') {
end = NULL;
} else {
if (*begin == ch)
end = begin;
else if (*begin == '\0')
end = NULL;
else
end = strchr (begin + 1, ch);
}
} else {
/* Find the end of the token. */
end = strpbrk (begin, delim);
}
if (end) {
/* Terminate the token and set *STRINGP past NUL character. */
*end++ = '\0';
*stringp = end;
} else {
/* No more delimiters; this is the last token. */
*stringp = NULL;
}
return begin;
}
/**
* get uid of current user. this is really stubbed, as it's only used
* as a check during startup (it fails normally if you run non-root, as it means
* that it can't drop privs, can't write pidfile, etc)
*/
int os_getuid(void) {
return 0;
}
int os_gettimeofday (struct timeval *tv, struct timezone* tz) {
union {
long long ns100; /*time since 1 Jan 1601 in 100ns units */
FILETIME ft;
} now;
GetSystemTimeAsFileTime (&now.ft);
tv->tv_usec = (long) ((now.ns100 / 10LL) % 1000000LL);
tv->tv_sec = (long) ((now.ns100 - 116444736000000000LL) / 10000000LL);
if(tz) {
tz->tz_minuteswest = _timezone;
}
return (0);
}
/**
* initialize winsock
*/
void _os_socket_startup(void) {
WORD minver;
int err;
minver = MAKEWORD( 2, 2 );
err = WSAStartup( minver, &w32_wsadata );
if ( err != 0 ) {
DPRINTF(E_FATAL,L_MISC,"Could not initialize winsock\n");
}
}
/**
* deinitialize winsock
*/
void _os_socket_shutdown(void) {
WSACleanup();
}
/* COMPAT FUNCTIONS */
/* can't be worse then strerror */
char *os_strerror (int error_no) {
static char buf[500];
if (error_no == 0)
error_no = GetLastError ();
buf[0] = '\0';
if (!FormatMessage (FORMAT_MESSAGE_FROM_SYSTEM, NULL,
error_no,
0, /* choose most suitable language */
buf, sizeof (buf), NULL))
sprintf (buf, "w32 error %u", error_no);
return buf;
}
/**
* get the default config path. there might be an argument to be made
* for using the install path as determined by registry, but might
* just be easiest to grab the directory the executable is running from
*
* @returns path to config file (from static buffer)
*/
char *os_configpath(void) {
char *config_path = _os_filepath("mt-daapd.conf");
char *working_path = _os_filepath("");
strcpy(os_config_file,config_path);
free(config_path);
if(_chdir(working_path) == -1) {
DPRINTF(E_LOG,L_MISC,"Could not chdir to %s... using c:\\\n",working_path);
if(_chdir("c:\\") == -1) {
DPRINTF(E_FATAL,L_MISC,"Could not chdir to c:\\... aborting\n");
}
}
free(working_path);
DPRINTF(E_DBG,L_MISC,"Using config file %s\n",os_config_file);
return os_config_file;
}
char *_os_filepath(char *file) {
char drive[_MAX_DRIVE];
char dir[_MAX_DIR];
char path[PATH_MAX];
GetModuleFileName(NULL,path,PATH_MAX);
_splitpath(path,drive,dir,NULL,NULL);
_makepath(path,drive,dir,NULL,NULL);
strcat(path,file);
return strdup(path);
}
/**
* get the path of the executable. Caller must free.
*
*/
char *os_apppath(char *junk) {
char app_path[PATH_MAX];
GetModuleFileName(NULL,app_path,PATH_MAX);
return strdup(app_path);
}
/**
* Determine if an address is local or not
*
* @param hostaddr the address to test for locality
*/
int os_islocaladdr(char *hostaddr) {
char hostname[256];
struct hostent *ht;
int index;
DPRINTF(E_DBG,L_MISC,"Checking if %s is local\n",hostaddr);
if(strncmp(hostaddr,"127.",4) == 0)
return TRUE;
gethostname(hostname, sizeof(hostname));
ht=gethostbyname(hostname);
index=0;
while(ht->h_addr_list[index] != NULL) {
/*
if(memcmp(&hostaddr,h_addr_list[index],4) == 0)
return TRUE;
*/
if(strcmp(inet_ntoa(*(struct in_addr *)ht->h_addr_list[index]),hostaddr) == 0) {
DPRINTF(E_DBG,L_MISC,"Yup!\n");
return TRUE;
}
index++;
}
DPRINTF(E_DBG,L_MISC,"Nope!\n");
return FALSE;
}
/**
* Lock the mutex. This is used for initialization stuff, among
* other things (?)
*/
void _os_lock(void) {
int err;
if((err=pthread_mutex_lock(&os_mutex))) {
DPRINTF(E_FATAL,L_MISC,"Cannot lock mutex\n");
}
}
/**
* Unlock the os mutex
*/
void _os_unlock(void) {
int err;
if((err=pthread_mutex_unlock(&os_mutex))) {
DPRINTF(E_FATAL,L_MISC,"Cannot unlock mutex\n");
}
}
/**
* load a loadable library
*/
void *os_loadlib(char **pe, char *path) {
void *retval;
UINT old_mode;
old_mode = SetErrorMode(SEM_NOOPENFILEERRORBOX | SEM_FAILCRITICALERRORS);
retval = (void*)LoadLibrary(path);
if(!retval) {
if(pe) *pe = strdup(os_strerror(0));
}
SetErrorMode(old_mode);
return retval;
}
void *os_libfunc(char **pe, void *handle, char *function) {
void *retval;
char *e;
retval = GetProcAddress((HMODULE)handle, function);
if(!retval) {
if(pe) {
*pe = strdup(os_strerror(0));
e = *pe;
while((e[strlen(e) - 1] == '\n') || (e[strlen(e)-1] == '\r'))
e[strlen(e)-1] = '\0';
}
}
return retval;
}
int os_unload(void *handle) {
FreeLibrary(handle);
return TRUE;
}
// Unicody stuff
/* opendir/closedir/readdir emulation taken from emacs. Thanks. :) */
DIR *os_opendir(char *filename) {
DIR *dirp;
/* Opening is done by FindFirstFile. However, a read is inherent to
this operation, so we defer the open until read time. */
if (!(dirp = (DIR *) malloc (sizeof (DIR))))
return NULL;
dirp->dir_find_handle = INVALID_HANDLE_VALUE;
dirp->dd_fd = 0;
dirp->dd_loc = 0;
dirp->dd_size = 0;
strncpy (dirp->dir_pathname, filename,PATH_MAX);
dirp->dir_pathname[PATH_MAX] = '\0';
return dirp;
}
void os_closedir(DIR *dirp) {
/* If we have a find-handle open, close it. */
if (dirp->dir_find_handle != INVALID_HANDLE_VALUE) {
FindClose(dirp->dir_find_handle);
}
free((char *) dirp);
}
int os_readdir_r(DIR *dirp, struct dirent *entry, struct dirent **result) {
char filename[PATH_MAX + 1];
WCHAR utf16[PATH_MAX + 1];
int ln;
if (dirp->dir_find_handle == INVALID_HANDLE_VALUE) {
/* If we aren't dir_finding, do a find-first, otherwise do a find-next. */
strncpy (filename, dirp->dir_pathname,PATH_MAX - 3);
ln = (int) strlen (filename) - 1;
if(filename[ln] != '\\')
strcat (filename, "\\");
strcat (filename, "*");
/* filename is utf-8... let's convert to unicode */
util_utf8toutf16((unsigned char *)&utf16,sizeof(utf16),filename,(int)strlen(filename));
dirp->dir_find_handle = FindFirstFileW(utf16, &dirp->dir_find_data);
if (dirp->dir_find_handle == INVALID_HANDLE_VALUE) {
*result=NULL;
return 2;
}
} else {
if (!FindNextFileW(dirp->dir_find_handle, &dirp->dir_find_data)) {
*result = NULL;
return 0;
}
}
/* Emacs never uses this value, so don't bother making it match
value returned by stat(). */
entry->d_ino = 1;
memset(entry->d_name,0,MAXNAMLEN+1);
util_utf16toutf8(entry->d_name,MAXNAMLEN+1,
(unsigned char *)&dirp->dir_find_data.cFileName,
(int)wcslen(dirp->dir_find_data.cFileName)*2);
entry->d_namlen = (int) strlen (entry->d_name);
entry->d_reclen = sizeof (struct dirent) - MAXNAMLEN + 3 +
entry->d_namlen - entry->d_namlen % 4;
entry->d_type = 0;
if(dirp->dir_find_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
entry->d_type |= DT_DIR;
} else if(dirp->dir_find_data.dwFileAttributes & FILE_ATTRIBUTE_NORMAL) {
entry->d_type |= DT_REG;
}
/*
if (dir_is_fat)
_strlwr (dir_static.d_name);
else if (!NILP (Vw32_downcase_file_names)) {
register char *p;
for (p = dir_static.d_name; *p; p++)
if (*p >= 'a' && *p <= 'z')
break;
if (!*p)
_strlwr (dir_static.d_name);
}
*/
*result = entry;
return 0;
}
/**
* this is now pretty close to a true realpath implementation
*/
char *os_realpath(const char *pathname, char *resolved_path) {
char *ptr;
WCHAR utf16_rel_path[PATH_MAX+1];
WCHAR utf16_path[PATH_MAX+1];
char *mapped_path;
/* need to take the utf-8 and convert to utf-16, then _fullpath, then back */
util_utf8toutf16((unsigned char *)&utf16_rel_path,PATH_MAX * sizeof(WCHAR),(char*)pathname,(int)strlen(pathname));
if(!_wfullpath(utf16_path,utf16_rel_path,PATH_MAX)) {
DPRINTF(E_FATAL,L_MISC,"Could not realpath %s\n",pathname);
}
util_utf16toutf8((unsigned char *)resolved_path,PATH_MAX,(unsigned char *)&utf16_path,
util_utf16_byte_len((unsigned char *)utf16_path));
ptr = resolved_path;
while(*ptr) {
// *ptr = tolower(*ptr);
if(*ptr == '/')
*ptr = '\\';
ptr++;
}
while(resolved_path[strlen(resolved_path)-1] == '\\') {
resolved_path[strlen(resolved_path)-1] = '\x0';
}
/* convert drive letter to unc path? */
if((resolved_path[0] != '\\')&&(os_maps_init)){
if((mapped_path = os_drive_maps[tolower(resolved_path[0]) - 'a'])) {
/* replace the x:\ with the path */
memmove(&resolved_path[strlen(mapped_path)],&resolved_path[3],strlen(resolved_path)-2); /* get the null */
memcpy(resolved_path,mapped_path,strlen(mapped_path));
}
}
return &resolved_path[0];
}
int os_stat(const char *path, struct _stat *sb) {
WCHAR utf16_path[PATH_MAX+1];
memset(utf16_path,0,sizeof(utf16_path));
util_utf8toutf16((unsigned char *)&utf16_path,PATH_MAX * 2,(char*)path,(int)strlen(path));
return _wstat(utf16_path,sb);
}
int os_lstat(const char *path, struct _stat *sb) {
return os_stat(path,sb);
}

View File

@ -1,65 +0,0 @@
/*
* $Id$
*
* os glue stuff, for functions that vary too greatly between
* win32 and unix
*/
#ifndef _OS_WIN32_H_
#define _OS_WIN32_H_
#include "stdlib.h"
#define MAXNAMLEN 255
#define DIRBLKSIZ 512
#define PATHSEP '\\'
#define PATHSEP_STR "\\"
#define S_ISDIR(a) ((a) & S_IFDIR)
struct timezone {
int tz_minuteswest;
int tz_dsttime;
};
#define DT_DIR 1
#define DT_REG 2
#define DT_LNK 4
#define W_OK 2
#define R_OK 4
struct dirent { /* data from readdir() */
long d_ino; /* inode number of entry */
unsigned short d_reclen; /* length of this record */
unsigned short d_namlen; /* length of string in d_name */
int d_type; /* flags */
char d_name[MAXNAMLEN+1]; /* name of file */
};
typedef struct {
int dd_fd; /* file descriptor */
int dd_loc; /* offset in block */
int dd_size; /* amount of valid data */
char dd_buf[DIRBLKSIZ]; /* directory block */
HANDLE dir_find_handle;
char dir_pathname[PATH_MAX+1];
WIN32_FIND_DATAW dir_find_data;
} DIR;
/* win32-specific functions -- set up service, etc */
extern int os_register(void);
extern int os_unregister(void);
extern char *os_configpath(void);
extern int os_getuid(void);
/* missing win32 functions */
extern char *os_strsep(char **stringp, const char *delim);
extern char *os_realpath(const char *pathname, char *resolved_path);
extern int os_gettimeofday (struct timeval *tv, struct timezone* tz);
extern int os_readdir_r(DIR *dirp, struct dirent *entry, struct dirent **result);
extern void os_closedir(DIR *dirp);
extern DIR *os_opendir(char *filename);
extern char *os_strerror (int error_no);
#endif /* _OS_WIN32_H_ */

View File

@ -49,10 +49,6 @@ extern int os_islocaladdr(char *hostaddr);
extern char *os_apppath(char *parm);
extern int os_signal_server(int what); /* signal a running server */
#ifdef WIN32
# include "os-win32.h"
#else
# include "os-unix.h"
#endif
#include "os-unix.h"
#endif

View File

@ -1,354 +0,0 @@
/*
* $Id: $
*
* Win32-only transcoder for WMA using the Windows Media Format SDK.
*/
#define _WIN32_DCOM
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <windows.h>
#include <mmreg.h>
#include <wmsdk.h>
#include "ff-plugins.h"
#ifndef TRUE
# define TRUE 1
# define FALSE 0
#endif
typedef struct tag_ssc_handle {
int state;
IWMSyncReader *pReader;
int errnum;
int duration;
char wav_header[44];
int wav_offset;
INSSBuffer *pBuffer;
BYTE *pdata;
DWORD data_len;
int offset;
DWORD channels;
DWORD sample_rate;
WORD bits_per_sample;
} SSCHANDLE;
#define STATE_DONE 0
#define STATE_OPEN 1
#define STATE_STREAMOPEN 2
#define SSC_WMA_E_SUCCESS 0
#define SSC_WMA_E_NOCOM 1
#define SSC_WMA_E_NOREADER 2
#define SSC_WMA_E_OPEN 3
#define SSC_WMA_E_READ 4
char *_ssc_wma_errors[] = {
"Success",
"Could not initialize COM",
"Could not create WMA reader",
"Could not open file",
"Error while reading file"
};
/* Forwards */
void *ssc_wma_init(void);
void ssc_wma_deinit(void *pv);
int ssc_wma_open(void *pv, MP3FILE *pmp3);
int ssc_wma_close(void *pv);
int ssc_wma_read(void *pv, char *buffer, int len);
char *ssc_wma_error(void *pv);
/* Globals */
PLUGIN_TRANSCODE_FN _ptfn = {
ssc_wma_init,
ssc_wma_deinit,
ssc_wma_open,
ssc_wma_close,
ssc_wma_read,
ssc_wma_error
};
PLUGIN_INFO _pi = {
PLUGIN_VERSION, /* version */
PLUGIN_TRANSCODE, /* type */
"ssc-wma/" VERSION, /* server */
NULL, /* output fns */
NULL, /* event fns */
&_ptfn, /* fns */
NULL, /* rend info */
"wma,wmal,wmap,wmav" /* codeclist */
};
/**
* return the string representation of the last error
*/
char *ssc_wma_error(void *pv) {
SSCHANDLE *handle = (SSCHANDLE*)pv;
return _ssc_wma_errors[handle->errnum];
}
PLUGIN_INFO *plugin_info(void) {
return &_pi;
}
void *ssc_wma_init(void) {
SSCHANDLE *handle;
HRESULT hr;
hr = CoInitializeEx(NULL,COINIT_MULTITHREADED);
if(FAILED(hr)) {
pi_log(E_INF,"Could not initialize COM, Error code: 0x%08X\n",hr);
return NULL;
}
handle=(SSCHANDLE *)malloc(sizeof(SSCHANDLE));
if(handle) {
memset(handle,0,sizeof(SSCHANDLE));
}
return (void*)handle;
}
void ssc_wma_deinit(void *vp) {
SSCHANDLE *handle = (SSCHANDLE *)vp;
ssc_wma_close(handle);
if(handle) {
free(handle);
CoUninitialize();
}
return;
}
int ssc_wma_open(void *vp, MP3FILE *pmp3) {
SSCHANDLE *handle = (SSCHANDLE*)vp;
HRESULT hr = S_OK;
WCHAR fname[PATH_MAX];
DWORD byte_count;
char *file;
char *codec;
int duration;
file = pmp3->path;
codec = pmp3->codectype;
duration = pmp3->song_length;
if(!handle)
return FALSE;
handle->state = STATE_DONE;
handle->duration = duration;
handle->errnum = SSC_WMA_E_OPEN;
hr = WMCreateSyncReader(NULL,0,&handle->pReader);
if(FAILED(hr)) {
pi_log(E_INF,"Could not create WMA reader. Error code: 0x%08X\n",hr);
handle->errnum = SSC_WMA_E_NOREADER;
return FALSE;
}
/* convert file name to wchar */
MultiByteToWideChar(CP_UTF8,0,file,-1,fname,sizeof(fname)/sizeof(fname[0]));
hr = handle->pReader->Open(fname);
if(FAILED(hr)) {
pi_log(E_INF,"Could not open file. Error code: 0x%08X\n",hr);
return FALSE;
}
handle->state=STATE_OPEN;
hr = handle->pReader->SetRange(0,0);
if(FAILED(hr)) {
pi_log(E_INF,"Could not set range. Error code: 0x%08X\n",hr);
return FALSE;
}
hr = handle->pReader->SetReadStreamSamples(1,0);
if(FAILED(hr)) {
pi_log(E_INF,"Could not stream samples. Error code: 0x%08X\n",hr);
return FALSE;
}
handle->channels = 2;
handle->bits_per_sample = 16;
handle->sample_rate = 44100;
IWMOutputMediaProps *pprops;
hr = handle->pReader->GetOutputFormat(0,0,&pprops);
if(FAILED(hr)) {
pi_log(E_LOG,"Could not get output format for %s\n",file);
return TRUE; /* we'll assume 44100/16/2 */
}
hr = pprops->GetMediaType(NULL,&byte_count);
if(FAILED(hr)) {
pi_log(E_LOG,"Could not get media type for %s\n",file);
return TRUE;
}
WM_MEDIA_TYPE *ptype = (WM_MEDIA_TYPE*)calloc(byte_count,1);
if(!ptype) {
pi_log(E_FATAL,"ssc_wma_open: malloc\n");
}
hr = pprops->GetMediaType(ptype, &byte_count);
if(FAILED(hr)) {
free(ptype);
return TRUE;
}
/* now get sample info */
if(ptype->formattype == WMFORMAT_WaveFormatEx) {
WAVEFORMATEX *pformat = (WAVEFORMATEX*)ptype->pbFormat;
handle->channels = pformat->nChannels;
handle->sample_rate = pformat->nSamplesPerSec;
handle->bits_per_sample = pformat->wBitsPerSample;
}
free(ptype);
return TRUE;
}
int ssc_wma_close(void *vp) {
SSCHANDLE *handle = (SSCHANDLE *)vp;
if(!handle)
return TRUE;
if(handle->state >= STATE_OPEN) {
handle->pReader->Close();
}
if(handle->pReader)
handle->pReader->Release();
handle->pReader = NULL;
handle->state = STATE_DONE;
return TRUE;
}
int ssc_wma_read(void *vp, char *buffer, int len) {
SSCHANDLE *handle = (SSCHANDLE *)vp;
int bytes_returned = 0;
int bytes_to_copy;
HRESULT hr;
unsigned int channels, sample_rate, bits_per_sample;
unsigned int byte_rate, block_align, duration;
QWORD sample_time=0, sample_duration=0;
DWORD sample_len=0, flags=0, output_number=0;
/* if we have not yet sent the header, let's do that first */
if(handle->wav_offset != sizeof(handle->wav_header)) {
/* still have some to send */
if(!handle->wav_offset) {
/* Should pull this from format info in the wma file */
channels = handle->channels;
sample_rate = handle->sample_rate;
bits_per_sample = handle->bits_per_sample;
if(handle->duration)
duration = handle->duration;
sample_len = ((bits_per_sample * sample_rate * channels / 8) * (duration/1000));
byte_rate = sample_rate * channels * bits_per_sample / 8;
block_align = channels * bits_per_sample / 8;
pi_log(E_DBG,"Channels.......: %d\n",channels);
pi_log(E_DBG,"Sample rate....: %d\n",sample_rate);
pi_log(E_DBG,"Bits/Sample....: %d\n",bits_per_sample);
memcpy(&handle->wav_header[0],"RIFF",4);
*((unsigned int*)(&handle->wav_header[4])) = 36 + sample_len;
memcpy(&handle->wav_header[8],"WAVE",4);
memcpy(&handle->wav_header[12],"fmt ",4);
*((unsigned int*)(&handle->wav_header[16])) = 16;
*((unsigned short*)(&handle->wav_header[20])) = 1;
*((unsigned short*)(&handle->wav_header[22])) = channels;
*((unsigned int*)(&handle->wav_header[24])) = sample_rate;
*((unsigned int*)(&handle->wav_header[28])) = byte_rate;
*((unsigned short*)(&handle->wav_header[32])) = block_align;
*((unsigned short*)(&handle->wav_header[34])) = bits_per_sample;
memcpy(&handle->wav_header[36],"data",4);
*((unsigned int*)(&handle->wav_header[40])) = sample_len;
}
bytes_to_copy = sizeof(handle->wav_header) - handle->wav_offset;
if(len < bytes_to_copy)
bytes_to_copy = len;
memcpy(buffer,&handle->wav_header[handle->wav_offset],bytes_to_copy);
handle->wav_offset += bytes_to_copy;
return bytes_to_copy;
}
/* see if we have any leftover data */
if(handle->data_len) {
bytes_returned = handle->data_len;
if(bytes_returned > len) {
bytes_returned = len;
}
memcpy(buffer,handle->pdata + handle->offset,bytes_returned);
handle->offset += bytes_returned;
handle->data_len -= bytes_returned;
if(!handle->data_len) {
handle->pBuffer->Release();
handle->pBuffer = NULL;
}
return bytes_returned;
}
handle->offset = 0;
hr = handle->pReader->GetNextSample(1,&handle->pBuffer,&sample_time, &sample_duration, &flags, &output_number, NULL);
if(SUCCEEDED(hr)) {
hr = handle->pBuffer->GetBufferAndLength(&handle->pdata, &handle->data_len);
if(FAILED(hr)) {
pi_log(E_LOG,"Read error while transcoding file\n");
handle->errnum = SSC_WMA_E_READ;
return -1;
}
// pi_log(E_SPAM,"Read %d bytes\n",handle->data_len);
bytes_returned = handle->data_len;
if(bytes_returned > len)
bytes_returned = len;
memcpy(buffer,handle->pdata + handle->offset,bytes_returned);
handle->offset += bytes_returned;
handle->data_len -= bytes_returned;
if(!handle->data_len) {
handle->pBuffer->Release();
handle->pBuffer = NULL;
}
} else {
return 0;
}
return bytes_returned;
}

View File

@ -1,74 +0,0 @@
/*
* $Id: $
*/
#include "compat.h"
#include "ff-plugins.h"
/* Forwards */
void plugin_handler(int, int, void *, int);
#define PIPE_BUFFER_SIZE 4096
/* Globals */
PLUGIN_EVENT_FN _pefn = { plugin_handler };
PLUGIN_INFO _pi = {
PLUGIN_VERSION, /* version */
PLUGIN_EVENT, /* type */
"w32-event/" VERSION, /* server */
NULL, /* output fns */
&_pefn, /* event fns */
NULL, /* transocde fns */
NULL, /* rend info */
NULL /* codec list */
};
typedef struct tag_plugin_msg {
int size;
int event_id;
int intval;
char vp[1];
} PLUGIN_MSG;
PLUGIN_INFO *plugin_info(void) {
return &_pi;
}
#define MAILSLOT_NAME "\\\\.\\mailslot\\FireflyMediaServer--67A72768-4154-417e-BFA0-FA9B50C342DE"
/** NO LOG IN HERE! We'll go into an endless loop. :) */
void plugin_handler(int event_id, int intval, void *vp, int len) {
HANDLE h = CreateFile(MAILSLOT_NAME, GENERIC_WRITE,
FILE_SHARE_READ, NULL, OPEN_EXISTING,
FILE_ATTRIBUTE_NORMAL, NULL);
if (h != INVALID_HANDLE_VALUE) {
DWORD bytes_written;
const int packet_size = 12 + len;
unsigned char *buffer = (unsigned char *)malloc(packet_size);
if(!buffer)
return;
memset(buffer, 0, packet_size);
buffer[0] = packet_size & 0xff;
buffer[1] = (packet_size >> 8) & 0xff;
buffer[2] = (packet_size >> 16) & 0xff;
buffer[3] = (packet_size >> 24) & 0xff;
buffer[4] = event_id & 0xff;
buffer[5] = (event_id >> 8) & 0xff;
buffer[6] = (event_id >> 16) & 0xff;
buffer[7] = (event_id >> 24) & 0xff;
buffer[8] = intval & 0xff;
buffer[9] = (intval >> 8) & 0xff;
buffer[10] = (intval >> 16) & 0xff;
buffer[11] = (intval >> 24) & 0xff;
memcpy(buffer + 12, vp, len);
/* If this fails then there's nothing we can do about it anyway. */
WriteFile(h, buffer, packet_size, &bytes_written, NULL);
CloseHandle(h);
}
}

View File

@ -1,234 +0,0 @@
/*
* $Id$
*
* This is an implementation of rendezvous using the Bonjour (tm)
* for windows dns_sd.h implementation
*/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <ctype.h>
#include <errno.h>
#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <sys/types.h>
#include "daapd.h"
#include "dns_sd.h"
#include "err.h"
/* Globals */
pthread_t rend_tid;
static volatile int rend_stop_flag = 0;
//static volatile int rend_timeout = 100000000; /* select timeout */
static volatile int rend_timeout=2;
static volatile int rend_count=0;
static pthread_mutex_t rend_mutex=PTHREAD_MUTEX_INITIALIZER;
typedef struct tag_rend_entry {
DNSServiceRef client;
struct tag_rend_entry *next;
} REND_ENTRY;
static REND_ENTRY rend_clients = { NULL, NULL };
/* Forwards */
void *rend_mainthread(void *arg);
void DNSSD_API rend_reg_reply(DNSServiceRef client, const DNSServiceFlags flags,
DNSServiceErrorType errorCode, const char *name,
const char *regtype, const char *domain, void *context);
/* Typedefs */
typedef union { unsigned char b[2]; unsigned short NotAnInteger; } Opaque16;
/**
* initialize the rendezvous interface.
*
* @param user user to drop privs to (ignored)
* @returns 0 on success, -1 with errno set otherwise
*/
int rend_init(char *user) {
/* we'll throw off a handler thread when we register a name */
return 0;
}
/* FIXME */
void rend_lock(void) {
if(pthread_mutex_lock(&rend_mutex))
DPRINTF(E_FATAL,L_MISC,"Could not lock mutex\n");
}
void rend_unlock(void) {
pthread_mutex_unlock(&rend_mutex);
}
/**
* main bonjourvous thread
*
* @param arg unused
*/
void *rend_mainthread(void *arg) {
/* this is pretty much right out of the old mdns stuff */
int nfds;
fd_set readfds;
fd_set *which;
struct timeval tv;
int result;
REND_ENTRY *current;
DNSServiceErrorType err = kDNSServiceErr_NoError;
while (!rend_stop_flag) {
FD_ZERO(&readfds);
rend_lock();
nfds=1;
current = rend_clients.next;
while(current) {
if(current->client) {
if(DNSServiceRefSockFD(current->client) > nfds)
nfds = DNSServiceRefSockFD(current->client) + 1;
FD_SET(DNSServiceRefSockFD(current->client),&readfds);
}
current = current->next;
}
rend_unlock();
tv.tv_sec = rend_timeout;
tv.tv_usec = 0;
result = select(nfds, &readfds, (fd_set*)NULL, (fd_set*)NULL, &tv);
if (result > 0) {
rend_lock();
current = rend_clients.next;
err=0;
while(current) {
if(current->client) {
if((!err) && (FD_ISSET(DNSServiceRefSockFD(current->client),&readfds))) {
err = DNSServiceProcessResult(current->client);
}
}
current = current->next;
}
rend_unlock();
if (err) {
DPRINTF(E_LOG,L_REND,"DNSServiceProcessResult returned %d\n", err);
rend_stop_flag = 1;
}
} else if (result == 0) {
DPRINTF(E_SPAM,L_REND,"rendezvous: tick!\n");
// myTimerCallBack();
} else {
DPRINTF(E_INF,L_REND,"select() returned %d errno %d %s\n", result, errno, strerror(errno));
if (errno != EINTR) rend_stop_flag = 1;
}
}
rend_lock();
while(current) {
if(current->client)
DNSServiceRefDeallocate(current->client);
current = current->next;
}
rend_unlock();
return NULL;
}
/**
* check to see if rendezvous is running.
*
* @returns TRUE if running, FALSE otherwise
*/
int rend_running(void) {
return TRUE;
}
/**
* stop rendezvous if it is running. There should really be a way
* to start it, would't one think?
*
* @returns TRUE if stopped, FALSE otherwise
*/
int rend_stop(void) {
return TRUE;
}
/**
* register a rendezvous name
*
* @param name long name to register (mt-daapd)
* @param type type to register (_daap._tcp)
* @param port port to register (3689)
* @param iface interface to register with (ignored)
* @returns TRUE if registered, FALSE otherwise
*/
int rend_register(char *name, char *type, int port, char *iface, char *txt) {
int err;
REND_ENTRY *pnew;
uint16_t port_netorder = htons((unsigned short)port);
pnew = (REND_ENTRY *)malloc(sizeof(REND_ENTRY));
if(!pnew)
return -1;
rend_lock();
pnew->client = NULL;
pnew->next = rend_clients.next;
rend_clients.next = pnew;
rend_unlock();
DPRINTF(E_INF,L_REND,"Registering %s as type (%s) on port %d\n",
name, type, port);
DNSServiceRegister(&pnew->client,0,kDNSServiceInterfaceIndexAny,name,type,"local",NULL,
port_netorder,(uint16_t)strlen(txt),txt,rend_reg_reply, NULL);
/* throw off a new thread work this */
if(!rend_count) {
if((err=pthread_create(&rend_tid,NULL,rend_mainthread,NULL))) {
DPRINTF(E_LOG,L_REND,"Could not spawn thread: %s\n",strerror(err));
errno=err;
return -1;
}
}
rend_count++;
return 0;
}
void DNSSD_API rend_reg_reply(DNSServiceRef client, const DNSServiceFlags flags,
DNSServiceErrorType errorCode, const char *name,
const char *regtype, const char *domain, void *context)
{
DPRINTF(E_INF,L_REND,"Got a reply for %s.%s%s\n", name, regtype, domain);
switch (errorCode) {
case kDNSServiceErr_NoError:
DPRINTF(E_INF,L_REND,"Name now registered and active\n");
break;
case kDNSServiceErr_NameConflict:
DPRINTF(E_FATAL,L_REND,"Rendezvous name in use, aborting...\n");
break;
default:
DPRINTF(E_FATAL,L_REND,"Error %d\n", errorCode);
return;
}
}
/**
* unregister a name
*
* unimplemented
*/
int rend_unregister(char *name, char *type, int port) {
return -1;
}

View File

@ -1,128 +0,0 @@
/*
* $Id$
*
* eventlog messages utility functions
*
* Copyright (C) 2005-2006 Ron Pedde (ron@pedde.com)
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <windows.h>
#include <stdio.h>
#include "daapd.h"
#include "messages.h"
static HANDLE elog_handle = NULL;
/**
* register eventlog functions
*
* @returns TRUE if successful, FALSE otherwise
*/
int elog_register(void) {
HKEY reg_key = NULL;
DWORD err = 0;
char path[PATH_MAX];
DWORD event_types;
wsprintf(path,"SYSTEM\\CurrentControlSet\\Services\\EventLog\\Application\\%s", PACKAGE);
if((err=RegCreateKey(HKEY_LOCAL_MACHINE, path, &reg_key)) != ERROR_SUCCESS)
return FALSE;
GetModuleFileName(NULL, path, PATH_MAX);
err=RegSetValueEx(reg_key, "EventMessageFile",0,REG_EXPAND_SZ,path,(DWORD)strlen(path) + 1);
if(err != ERROR_SUCCESS) {
RegCloseKey(reg_key);
return FALSE;
}
event_types = EVENTLOG_ERROR_TYPE | EVENTLOG_WARNING_TYPE | EVENTLOG_INFORMATION_TYPE;
err=RegSetValueEx(reg_key,"TypesSupported", 0, REG_DWORD, (BYTE*)&event_types, sizeof event_types );
if(err != ERROR_SUCCESS) {
RegCloseKey(reg_key);
return FALSE;
}
RegCloseKey(reg_key);
return TRUE;
}
/**
* FIXME: ENOTIMPL
*/
int elog_unregister(void) {
return TRUE;
}
/**
* initialize the eventlog
*
* @returns TRUE if successful, FALSE otherwise
*/
int elog_init(void) {
elog_handle=RegisterEventSource(NULL, PACKAGE);
if(elog_handle == INVALID_HANDLE_VALUE)
return FALSE;
return TRUE;
}
/**
* uninitialize the eventlog
*
* @returns TRUE
*/
int elog_deinit(void) {
DeregisterEventSource(elog_handle);
return TRUE;
}
/**
* log a message to the event viewer
*
* @param level event level to log: 0=fatal, 3=warn, > info
* @returns TRUE on success, FALSE otherwise
*/
int elog_message(int level, char *msg) {
WORD message_level = EVENTLOG_INFORMATION_TYPE;
int ret;
if(level == 0)
message_level = EVENTLOG_ERROR_TYPE;
ret = ReportEvent(
elog_handle,
message_level,
0,
EVENT_MSG,
NULL,
1,
0,
&msg,
NULL);
/* ReportEvent returns non-zero on success */
return ret ? TRUE : FALSE;
}

View File

@ -1,32 +0,0 @@
/*
* $Id$
*
* eventlog messages utility functions
*
* Copyright (C) 2005 Ron Pedde (ron.pedde@firstmarkcu.org)
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef _EVENTLOG_H_
#define _EVENTLOG_H_
extern int elog_register(void);
extern int elog_unregister(void);
extern int elog_init(void);
extern int elog_deinit(void);
extern int elog_message(int level, char *msg);
#endif /* _EVENTLOG_H_ */

View File

@ -1,292 +0,0 @@
/*
* $Id$
*
* simple service management functions
*
* Copyright (C) 2005 Ron Pedde (ron.pedde@firstmarkcu.org)
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <windows.h>
#include "daapd.h"
#include "err.h"
/* Forwards */
BOOL service_update_status (DWORD,DWORD,DWORD,DWORD,DWORD);
void service_mainfunc(DWORD, LPTSTR *);
void service_init(void);
void service_handler(DWORD);
/* Globals */
SERVICE_STATUS_HANDLE service_status_handle = NULL;
HANDLE service_kill_event = NULL;
DWORD service_current_status;
/**
* handle the stop, start, pause requests, etc.
*
* @param code action the SCM wants us to take
*/
void service_handler(DWORD code) {
switch(code) {
case SERVICE_CONTROL_INTERROGATE:
break;
case SERVICE_CONTROL_SHUTDOWN:
// fallthrough
case SERVICE_CONTROL_STOP:
service_update_status(SERVICE_STOP_PENDING, NO_ERROR, 0, 1, 5000);
SetEvent(service_kill_event);
return;
default:
break;
}
service_update_status(service_current_status, NO_ERROR, 0, 0, 0);
}
/**
* exit the service as gracefully as possible, returning the error
* level specified. I think there are some state machine problems
* here, but probably nothing fatal -- an unnecessary call to
* xfer_shutdown, maybe. That's about it.
*
* @param errorlevel errorlevel to return
*/
void service_shutdown(int errorlevel) {
DPRINTF(E_INF,L_MISC,"Service about to terminate with error %d\n",errorlevel);
if(service_current_status != SERVICE_STOPPED) {
service_update_status(SERVICE_STOP_PENDING, NO_ERROR, 0, 1, 5000);
config.stop = 1;
service_update_status(SERVICE_STOPPED,errorlevel,0,0,3000);
}
if(service_kill_event) {
SetEvent(service_kill_event);
CloseHandle(service_kill_event);
}
// exit(errorlevel);
/* we'll let the main process exit (or hang!) */
Sleep(5000);
exit(1);
}
/**
* The main for the service -- starts up the service and
* makes it run. This sits in a tight loop until the service
* is shutdown. If this function exits, it's because the
* service is stopping.
*
* @param argc argc as passed from SCM
* @param argv argv as passed from SCM
*/
void service_mainfunc(DWORD argc, LPTSTR *argv) {
BOOL success;
service_current_status = SERVICE_STOPPED;
service_status_handle = RegisterServiceCtrlHandler(PACKAGE,
(LPHANDLER_FUNCTION) service_handler);
if(!service_status_handle) {
service_shutdown(GetLastError());
return;
}
// Next Notify the Service Control Manager of progress
success = service_update_status(SERVICE_START_PENDING, NO_ERROR, 0, 1, 5000);
if (!success) {
service_shutdown(GetLastError());
return;
}
service_kill_event = CreateEvent (0, TRUE, FALSE, 0);
if(!service_kill_event) {
service_shutdown(GetLastError());
return;
}
// FIXME
// startup errors generate an ERR_FATAL, which exit()s in the
// logging code -- fine for console apps, not so good here.
// Generates ugly error messages from the service tool.
// (terminated unexpectedly).
// xfer_startup();
// The service is now running. Notify the SCM of this fact.
service_current_status = SERVICE_RUNNING;
success = service_update_status(SERVICE_RUNNING, NO_ERROR, 0, 0, 0);
if (!success) {
service_shutdown(GetLastError());
return;
}
// Now just wait for our killed service signal, and then exit, which
// terminates the service!
WaitForSingleObject (service_kill_event, INFINITE);
service_shutdown(0);
}
/**
* update the scm service status, so it can make pretty
* gui stupidness. light wrapper around SetServiceStatus
*
* If the visual studio editor wasn't so horribly useless
* and munge up the indents, I'd split these parameters
* into several lines, but Microsoft apparently can't build
* an editor that is as good as that made by volunteers.
*
* Those who do not understand Unix are condemned to reinvent
* it, poorly. -- Henry Spencer
*
* @param dwCurrentState new service state
* @param dwWin32ExitCode exit code if state is SERVICE_STOPPED
* @param dwServiceSpecificExitCode specified service exit code
* @param dwCheckPoint incremented value for long startups
* @param dwWaitHint how to before giving up on the service
*
* @returns result of SetServiceStatus - true on success
*/
BOOL service_update_status (DWORD dwCurrentState, DWORD dwWin32ExitCode, DWORD dwServiceSpecificExitCode, DWORD dwCheckPoint, DWORD dwWaitHint) {
BOOL success;
SERVICE_STATUS serviceStatus;
service_current_status = dwCurrentState;
serviceStatus.dwServiceType = SERVICE_WIN32_OWN_PROCESS;
serviceStatus.dwCurrentState = dwCurrentState;
if (dwCurrentState == SERVICE_START_PENDING) {
serviceStatus.dwControlsAccepted = 0;
} else {
serviceStatus.dwControlsAccepted =
SERVICE_ACCEPT_STOP |
SERVICE_ACCEPT_SHUTDOWN;
}
if (dwServiceSpecificExitCode == 0) {
serviceStatus.dwWin32ExitCode = dwWin32ExitCode;
} else {
serviceStatus.dwWin32ExitCode = ERROR_SERVICE_SPECIFIC_ERROR;
}
serviceStatus.dwServiceSpecificExitCode = dwServiceSpecificExitCode;
serviceStatus.dwCheckPoint = dwCheckPoint;
serviceStatus.dwWaitHint = dwWaitHint;
success = SetServiceStatus (service_status_handle, &serviceStatus);
if (!success) {
SetEvent(service_kill_event);
}
return success;
}
/**
* kick off the application when in service mdoe - suitable for threadprocing
*/
void *service_startup(void *arg) {
SERVICE_TABLE_ENTRY serviceTable[] = {
{ PACKAGE, (LPSERVICE_MAIN_FUNCTION) service_mainfunc },
{ NULL, NULL }
};
BOOL success;
// Register the service with the Service Control Manager
// If it were to fail, what would we do, anyway?
success = StartServiceCtrlDispatcher(serviceTable);
return NULL;
}
/**
* install the service
*/
void service_register(void) {
SC_HANDLE scm;
SC_HANDLE svc;
char path[PATH_MAX];
GetModuleFileName(NULL, path, PATH_MAX );
if(!(scm = OpenSCManager(0,0,SC_MANAGER_CREATE_SERVICE))) {
DPRINTF(E_FATAL,L_MISC,"Cannot open service control manager\n");
}
svc = CreateService(scm,PACKAGE,SERVICENAME,SERVICE_ALL_ACCESS,
SERVICE_WIN32_OWN_PROCESS,SERVICE_AUTO_START,SERVICE_ERROR_NORMAL,
path,0,0,0,0,0);
if(!svc) {
DPRINTF(E_FATAL,L_MISC,"Cannot create service: %d\n",GetLastError());
}
CloseServiceHandle(svc);
CloseServiceHandle(scm);
DPRINTF(E_LOG,L_MISC,"Registered service successfully\n");
}
/**
* uninstall the service
*/
void service_unregister(void) {
SC_HANDLE scm;
SC_HANDLE svc;
BOOL res;
SERVICE_STATUS status;
if(!(scm = OpenSCManager(0,0,SC_MANAGER_CREATE_SERVICE))) {
DPRINTF(E_FATAL,L_MISC,"Cannot open service control manager: %d\n",GetLastError());
}
svc = OpenService(scm,PACKAGE,SERVICE_ALL_ACCESS | DELETE);
if(!svc) {
DPRINTF(E_FATAL,L_MISC,"Cannot open service: %d (is it installed??)\n",GetLastError());
}
res=QueryServiceStatus(svc,&status);
if(!res) {
DPRINTF(E_FATAL,L_MISC,"Cannot query service status: %d\n",GetLastError());
}
if(status.dwCurrentState != SERVICE_STOPPED) {
DPRINTF(E_LOG,L_MISC,"Stopping service...\n");
ControlService(svc,SERVICE_CONTROL_STOP,&status);
// we should probably poll for service stoppage...
Sleep(2000);
}
DPRINTF(E_LOG,L_MISC,"Deleting service...\n");
res = DeleteService(svc);
if(res) {
DPRINTF(E_LOG,L_MISC,"Deleted successfully\n");
} else {
DPRINTF(E_FATAL,L_MISC,"Error deleting service: %d\n",GetLastError());
}
CloseServiceHandle(svc);
CloseServiceHandle(scm);
}

View File

@ -1,32 +0,0 @@
/*
* $Id$
*
* simple service management functions
*
* Copyright (C) 2005 Ron Pedde (ron.pedde@firstmarkcu.org)
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef _SERVICE_H_
#define _SERVICE_H_
extern void *service_startup(void *);
extern void service_shutdown(int);
extern void service_register(void);
extern void service_unregister(void);
#endif /* _SERVICE_H_ */

View File

@ -1,101 +0,0 @@
/*
* $Id$
*
* Win32 compatibility stuff
*/
#ifndef _WIN32_H_
#define _WIN32_H_
// Visual C++ 2005 has a secure CRT that generates oodles of warnings when unbounded
// C library functions are used. Disable this feature for the time being.
#if defined(_MSC_VER)
# if _MSC_VER >= 1400
# define _CRT_SECURE_NO_DEPRECATE 1
# define _CRT_NONSTDC_NO_DEPRECATE 1
# endif
#endif
// Don't pull in winsock...
#define WIN32_LEAN_AND_MEAN
// Must include all these before defining the non-underscore versions
// otherwise the prototypes will go awry.
#include <windows.h>
//#include <io.h>
#include <stddef.h>
#include <fcntl.h>
#include <direct.h>
#include <stdio.h>
/* Type fixups */
#define mode_t int
#define ssize_t int
//#define socklen_t int
/* Consts */
#define PIPE_BUF 256 /* What *should* this be on win32? */
#define MAXDESC 512 /* http://msdn.microsoft.com/en-us/library/kdfaxaay.aspx */
#define ETIME 101
#define PATH_MAX 2048 /* it's clearly not _MAX_PATH... other projects seem to use 512 */
#define MAX_NAME_LEN _MAX_PATH
#define EADDRINUSE WSAEADDRINUSE
#define S_IFLNK 0x1
#define HOST "unknown-windows-ick"
#define SERVICENAME "Firefly Media Server"
#include "os-win32.h"
#ifndef TRUE
# define TRUE 1
# define FALSE 0
#endif
typedef UINT8 uint8_t;
typedef INT8 int8_t;
typedef UINT16 uint16_t;
typedef INT16 int16_t;
typedef UINT32 uint32_t;
typedef INT32 int32_t;
typedef UINT64 uint64_t;
typedef INT64 int64_t;
/* Funtion fixups */
#define usleep Sleep
#define sleep(a) Sleep((a) * 1000)
#define mkdir(a,b) _mkdir((a))
#define strtoll strtol /* FIXME: compat functions */
#define atoll atol
#define realpath os_realpath
#define strsep os_strsep
#define strncasecmp strnicmp
#define strcasecmp stricmp
#define snprintf _snprintf
#define vsnprintf _vsnprintf
#define access _access
#define readdir_r os_readdir_r
#define closedir os_closedir
#define opendir os_opendir
#define getuid os_getuid
#define strerror os_strerror /* FIXME: get rid of posix errors */
/* override the uici stuff */
// #define u_open os_opensocket
// #define u_accept os_acceptsocket
/* privately implemented functions: @see os-win32.c */
#define gettimeofday os_gettimeofday
#define CONFFILE os_configpath()
extern char *os_configpath(void);
#endif /* _WIN32_H_ */

View File

@ -1,146 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "AboutPage.h"
#include "FireflyShell.h"
#include "VersionInfo.h"
#include "DosPath.h"
LRESULT CAboutPage::OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/)
{
m_firefly_link.SubclassWindow(GetDlgItem(IDC_FIREFLYLINK));
m_firefly_link.SetHyperLink(_T("http://forums.fireflymediaserver.org"));
m_roku_link.SetHyperLink(_T("http://www.rokulabs.com"));
m_roku_link.SubclassWindow(GetDlgItem(IDC_ROKULINK));
// Do this before we try and use the controls.
DoDataExchange(false);
FillVersionList();
return 0;
}
void CAboutPage::FillVersionList()
{
CWaitCursor wait;
m_versions.Empty();
// Initialise the list control
CString str;
str.LoadString(IDS_VERSIONINFO_DESCRIPTION);
m_list.AddColumn(str, SUBITEM_DESCRIPTION);
str.LoadString(IDS_VERSIONINFO_VERSION);
m_list.AddColumn(str, SUBITEM_VERSION, 1);
str.LoadString(IDS_VERSIONINFO_PATH);
m_list.AddColumn(str, SUBITEM_PATH, 2);
m_list.SetColumnWidth(SUBITEM_DESCRIPTION, 40);
m_list.SetColumnWidth(SUBITEM_VERSION, 40);
CDosPath server_path(GetApplication()->GetServiceBinaryPath());
AddEntry(server_path.GetPath(), _T("Firefly server"));
AddEntry(CDosPath::AppPath().GetPath(), _T("FireflyShell"));
CString plugins_path = server_path.GetPathOnly() + _T("plugins\\");
CString plugins_pattern = plugins_path + _T("*.dll");
WIN32_FIND_DATA find;
HANDLE hFind = FindFirstFile(plugins_pattern, &find);
if (hFind != INVALID_HANDLE_VALUE)
{
do
{
AddEntry(plugins_path + find.cFileName, CString(find.cFileName) + _T(" plugin"));
} while (FindNextFile(hFind, &find));
FindClose(hFind);
}
for(int i = 0; i < SUBITEM_COUNT; ++i)
{
m_list.SetColumnWidth(i, m_column_widths[i] + 16);
}
}
void CAboutPage::AddEntry(const TCHAR *path, const TCHAR *fallback_description)
{
VersionInfo vi;
CString description = fallback_description;
CString version;
if (vi.Open(path))
{
description = vi.GetFileDescription();
version = vi.GetFileVersion();
}
int item = m_list.GetItemCount();
AddItem(item, SUBITEM_DESCRIPTION, description);
AddItem(item, SUBITEM_VERSION, version);
AddItem(item, SUBITEM_PATH, path);
CString line;
line.Format(_T("%s\t%s\t%s\r\n"), description, version, path);
m_versions += line;
}
void CAboutPage::AddItem(int item, int subitem, const TCHAR *text)
{
m_list.AddItem(item, subitem, text);
const int width = m_list.GetStringWidth(text);
if (width > m_column_widths[subitem])
m_column_widths[subitem] = width;
}
LRESULT CAboutPage::OnCopy(WORD, WORD, HWND, BOOL &)
{
if (OpenClipboard())
{
const size_t len = m_versions.GetLength() * sizeof(TCHAR);
HGLOBAL h = ::GlobalAlloc(GMEM_MOVEABLE, len);
if (h)
{
void *buffer = ::GlobalLock(h);
memcpy(buffer, static_cast<const TCHAR *>(m_versions), len);
::GlobalUnlock(h);
EmptyClipboard();
#if defined(UNICODE)
SetClipboardData(CF_UNICODETEXT, h);
#else
SetClipboardData(CF_TEXT, h);
#endif
}
CloseClipboard();
}
return 0;
}
LRESULT CAboutPage::OnCtlColorStatic(HDC hdc, HWND hwnd)
{
if (GetDlgItem(IDC_LOGO) == hwnd)
{
HBRUSH brush = (HBRUSH)::GetStockObject(WHITE_BRUSH);
return (LRESULT)brush;
}
else
return 0;
}

View File

@ -1,75 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef ABOUTPAGE_H
#define ABOUTPAGE_H 1
#include "resource.h"
class CAboutPage :
public CPropertyPageImpl<CAboutPage>,
public CWinDataExchange<CAboutPage>
{
typedef CPropertyPageImpl<CAboutPage> base;
CListViewCtrl m_list;
enum
{
SUBITEM_DESCRIPTION = 0,
SUBITEM_VERSION = 1,
SUBITEM_PATH = 2,
SUBITEM_COUNT = 3
};
int m_column_widths[SUBITEM_COUNT];
CHyperLink m_roku_link;
CHyperLink m_firefly_link;
// String version of information ready to write to the clipboard
CString m_versions;
public:
CAboutPage()
{
::ZeroMemory(m_column_widths, sizeof(m_column_widths));
}
enum { IDD = IDD_PAGE_ABOUT };
private:
// Message Handlers
BEGIN_MSG_MAP(CAboutPage)
MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
COMMAND_ID_HANDLER(IDC_COPY, OnCopy)
MSG_WM_CTLCOLORSTATIC(OnCtlColorStatic)
CHAIN_MSG_MAP(base)
END_MSG_MAP()
BEGIN_DDX_MAP(CAboutPage)
DDX_CONTROL_HANDLE(IDC_VERSIONLIST, m_list)
END_DDX_MAP()
LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
LRESULT OnCopy(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
LRESULT OnCtlColorStatic(HDC, HWND);
void FillVersionList();
void AddEntry(const TCHAR *path, const TCHAR *fallback_description);
void AddItem(int item, int subitem, const TCHAR *text);
};
#endif // ABOUTPAGE_H

View File

@ -1,159 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "AdvancedPage.h"
#include "IniFile.h"
#include "FireflyShell.h"
LRESULT CAdvancedPage::OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/)
{
CWaitCursor wait;
IniFile ini(GetApplication()->GetConfigPath());
m_server_port = ini.GetInteger(_T("general"), _T("port"), 9999);
DoDataExchange(false);
m_port_spin.SetRange32(1, 65535);
if(GetApplication()->IsServiceAutoStartEnabled())
m_autostart_check.SetCheck(BST_CHECKED);
else
m_autostart_check.SetCheck(BST_UNCHECKED);
if(GetApplication()->IsAppletAutoStartEnabled())
m_autostart_icon_check.SetCheck(BST_CHECKED);
else
m_autostart_icon_check.SetCheck(BST_UNCHECKED);
UpdateControls();
GetDlgItem(IDC_STARTSERVICE).SendMessage(BCM_SETSHIELD,0,TRUE);
GetDlgItem(IDC_STOPSERVICE).SendMessage(BCM_SETSHIELD,0,TRUE);
GetDlgItem(IDC_AUTOSTART).SendMessage(BCM_SETSHIELD,0,TRUE);
GetApplication()->ServiceStatusSubscribe(this);
return 0;
}
void CAdvancedPage::OnDestroy() {
GetApplication()->ServiceStatusUnsubscribe(this);
}
void CAdvancedPage::UpdateControls() {
Service::Status status = GetApplication()->GetServiceStatus();
UpdateControls(status);
}
void CAdvancedPage::UpdateControls(Service::Status status)
{
UINT state_id;
if (status.IsPending())
{
state_id = IDS_SERVER_PENDING;
GetDlgItem(IDC_STARTSERVICE).ShowWindow(SW_HIDE);
GetDlgItem(IDC_STOPSERVICE).ShowWindow(SW_HIDE);
}
else if (status.IsRunning())
{
state_id = IDS_SERVER_RUNNING;
GetDlgItem(IDC_STARTSERVICE).ShowWindow(SW_HIDE);
GetDlgItem(IDC_STOPSERVICE).ShowWindow(SW_SHOW);
}
else
{
state_id = IDS_SERVER_STOPPED;
GetDlgItem(IDC_STARTSERVICE).ShowWindow(SW_SHOW);
GetDlgItem(IDC_STOPSERVICE).ShowWindow(SW_HIDE);
}
const bool can_configure = GetApplication()->CanConfigure();
GetDlgItem(IDC_SERVERPORT).EnableWindow(can_configure);
GetDlgItem(IDC_PORTSPIN).EnableWindow(can_configure);
// If we can't control the service then don't give the user
// the impression that we can.
const bool can_control = GetApplication()->CanControlService();
GetDlgItem(IDC_STARTSERVICE).EnableWindow(can_control);
GetDlgItem(IDC_STOPSERVICE).EnableWindow(can_control);
GetDlgItem(IDC_AUTOSTART).EnableWindow(can_control);
CString state;
state.LoadString(state_id);
if (!can_control)
{
CString s;
s.LoadString(IDS_NOT_ADMIN);
state += " ";
state += s;
}
GetDlgItem(IDC_SERVERSTATE).SetWindowText(state);
}
int CAdvancedPage::OnApply()
{
CWaitCursor wait;
ATLTRACE("CAdvancedPage::OnApply\n");
if (!DoDataExchange(true))
return false;
IniFile ini(GetApplication()->GetConfigPath());
ini.SetInteger(_T("general"), _T("port"), m_server_port);
GetApplication()->EnableServiceAutoStart(m_hWnd,m_autostart_check.GetCheck() == BST_CHECKED);
GetApplication()->EnableAppletAutoStart(m_hWnd,m_autostart_icon_check.GetCheck() == BST_CHECKED);
// Incorrectly documented in WTL
return true;
}
LRESULT CAdvancedPage::OnStartService(WORD /*wNotifyCode*/, WORD /*wID*/, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
GetApplication()->StartService(m_hWnd);
UpdateControls();
return 0;
}
LRESULT CAdvancedPage::OnStopService(WORD /*wNotifyCode*/, WORD /*wID*/, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
GetApplication()->StopService(m_hWnd);
UpdateControls();
return 0;
}
LRESULT CAdvancedPage::OnWebAdmin(WORD /*wNotifyCode*/, WORD /*wID*/, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
CWaitCursor wait;
// Go to the config file because we might not have committed a change yet.
IniFile ini(GetApplication()->GetConfigPath());
unsigned int port = ini.GetInteger(_T("general"), _T("port"), 9999);
CString url;
url.Format(_T("http://localhost:%u/"), port);
::ShellExecute(m_hWnd, _T("open"), url, NULL, NULL, SW_SHOWNORMAL);
return 0;
}
void CAdvancedPage::OnServiceStatus(Service::Status old_status, Service::Status new_status)
{
UpdateControls(new_status);
}

View File

@ -1,87 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef ADVANCEDPAGE_H
#define ADVANCEDPAGE_H 1
#include "resource.h"
#include "ServiceControl.h"
/// @todo Users shouldn't be able to paste non-numbers into the port number.
class CAdvancedPage :
public CPropertyPageImpl<CAdvancedPage>,
public CWinDataExchange<CAdvancedPage>,
public ServiceStatusObserver
{
public:
enum { IDD = IDD_PAGE_ADVANCED };
private:
typedef CPropertyPageImpl<CAdvancedPage> base;
enum ServiceState
{
Pending = 0,
Running = 1,
Stopped = 2
};
enum { TIMER_ID = 42 };
unsigned int m_server_port;
CUpDownCtrl m_port_spin;
CButton m_autostart_check;
CButton m_autostart_icon_check;
void UpdateControls(Service::Status status);
void UpdateControls();
// ServiceStatusObserver
void OnServiceStatus(Service::Status old_status, Service::Status new_status);
BEGIN_MSG_MAP(CAdvancedPage)
MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
COMMAND_HANDLER_EX(IDC_SERVERPORT, EN_CHANGE, OnChange)
COMMAND_ID_HANDLER(IDC_STARTSERVICE, OnStartService)
COMMAND_ID_HANDLER(IDC_STOPSERVICE, OnStopService)
COMMAND_ID_HANDLER(IDC_WEBADMIN, OnWebAdmin)
MSG_WM_DESTROY(OnDestroy)
CHAIN_MSG_MAP(base)
END_MSG_MAP()
BEGIN_DDX_MAP(CAdvancedPage)
DDX_UINT(IDC_SERVERPORT, m_server_port);
DDX_CONTROL_HANDLE(IDC_PORTSPIN, m_port_spin);
DDX_CONTROL_HANDLE(IDC_AUTOSTART, m_autostart_check);
DDX_CONTROL_HANDLE(IDC_AUTOSTART_ICON, m_autostart_icon_check);
END_DDX_MAP()
// MessageHandlers;
LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
LRESULT OnStartService(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
LRESULT OnStopService(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
LRESULT OnWebAdmin(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
void OnDestroy();
void OnTimer(UINT id, TIMERPROC proc);
int OnApply();
void OnChange(UINT uCode, int nCtrlID, HWND hwndCtrl) {
// Lots of things could have changed.
SetModified();
}
};
#endif // ADVANCEDPAGE_H

View File

@ -1,93 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "ConfigPage.h"
#include "FireflyShell.h"
#include "IniFile.h"
LRESULT CConfigPage::OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/)
{
CWaitCursor wait;
IniFile ini(GetApplication()->GetConfigPath());
m_server_name = ini.GetString(_T("general"), _T("servername"), _T("Firefly media server"));
m_media_path = ini.GetString(_T("general"), _T("mp3_dir"), _T("C:\\Music"));
m_password = ini.GetString(_T("general"), _T("password"), _T(""));
// Do this before we try and use the controls.
DoDataExchange(false);
const bool enable_password = !m_password.IsEmpty();
m_protect_checkbox.SetCheck(enable_password);
EnableControls();
return 0;
}
void CConfigPage::EnableControls()
{
const bool enable = GetApplication()->CanConfigure();
GetDlgItem(IDC_SERVERNAME).EnableWindow(enable);
GetDlgItem(IDC_PATH).EnableWindow(enable);
GetDlgItem(IDC_PROTECT).EnableWindow(enable);
GetDlgItem(IDC_BROWSE).EnableWindow(enable);
const bool enable_password = (m_protect_checkbox.GetCheck() != 0) && enable;
GetDlgItem(IDC_PASSWORD).EnableWindow(enable_password);
//GetDlgItem(IDC_PASSWORD_PROMPT).EnableWindow(enable_password);
}
int CConfigPage::OnApply()
{
CWaitCursor wait;
ATLTRACE("CConfigPage::OnApply\n");
if (!DoDataExchange(true))
return false;
IniFile ini(GetApplication()->GetConfigPath());
ini.SetString(_T("general"), _T("servername"), m_server_name);
ini.SetString(_T("general"), _T("mp3_dir"), m_media_path);
ini.SetString(_T("general"), _T("password"), m_password);
// Incorrectly documented in WTL
return true;
}
LRESULT CConfigPage::OnBrowse(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
CFolderDialog folder;
// Who cares if it fails.
DoDataExchange(true);
folder.SetInitialFolder(m_media_path);
if (folder.DoModal() == IDOK)
{
m_media_path = folder.GetFolderPath();
DoDataExchange(false);
}
return 0;
}
void CConfigPage::OnClickProtect(UINT uCode, int nCtrlID, HWND hwndCtrl)
{
EnableControls();
SetModified();
}

View File

@ -1,70 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef CONFIGPAGE_H
#define CONFIGPAGE_H 1
#include "resource.h"
class CMainDlg;
class CConfigPage :
public CPropertyPageImpl<CConfigPage>,
public CWinDataExchange<CConfigPage>
{
typedef CPropertyPageImpl<CConfigPage> base;
public:
enum { IDD = IDD_PAGE_BASIC };
private:
CString m_media_path;
CString m_server_name;
CString m_password;
CButton m_protect_checkbox;
void EnableControls();
BEGIN_MSG_MAP(thisClass)
MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
COMMAND_ID_HANDLER(IDC_BROWSE, OnBrowse)
COMMAND_HANDLER_EX(IDC_PROTECT, BN_CLICKED, OnClickProtect)
COMMAND_HANDLER_EX(IDC_PASSWORD, EN_CHANGE, OnChange)
COMMAND_HANDLER_EX(IDC_SERVERNAME, EN_CHANGE, OnChange)
COMMAND_HANDLER_EX(IDC_PATH, EN_CHANGE, OnChange)
CHAIN_MSG_MAP(base)
END_MSG_MAP()
BEGIN_DDX_MAP(CConfigPage)
DDX_TEXT(IDC_PATH, m_media_path);
DDX_TEXT(IDC_SERVERNAME, m_server_name);
DDX_TEXT(IDC_PASSWORD, m_password);
DDX_CONTROL_HANDLE(IDC_PROTECT, m_protect_checkbox);
END_DDX_MAP()
// Message handlers
LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
LRESULT OnBrowse(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
void OnClickProtect(UINT uCode, int nCtrlID, HWND hwndCtrl);
int OnApply();
void OnChange(UINT uCode, int nCtrlID, HWND hwndCtrl)
{
// Lots of things could have changed.
SetModified();
}
};
#endif // CONFIGPAGE_H

View File

@ -1,173 +0,0 @@
/*
* (C) 1997, 2006 Mike Crowe
*
* License: Do what you like with it except claim that you wrote it.
*/
#include "stdafx.h"
#include "dospath.h"
#include <stdlib.h>
#include <direct.h>
CDosPath::CDosPath(const TCHAR *pszPath, int nFlags)
{
SetPath(pszPath, nFlags);
}
CDosPath::CDosPath(const CDosPath &old)
{
m_drive = old.m_drive;
m_dir = old.m_dir;
m_file = old.m_file;
m_ext = old.m_ext;
}
CDosPath &CDosPath::operator=(const CDosPath &old)
{
m_drive = old.m_drive;
m_dir = old.m_dir;
m_file = old.m_file;
m_ext = old.m_ext;
return *this;
}
CDosPath::~CDosPath()
{
}
void CDosPath::SplitPath(const TCHAR *path)
{
#if USE_SECURE
_tsplitpath_s(path, m_drive.GetBufferSetLength(_MAX_DRIVE), _MAX_DRIVE,
m_dir.GetBufferSetLength(_MAX_DIR), _MAX_DIR,
m_file.GetBufferSetLength(_MAX_FNAME), _MAX_FNAME,
m_ext.GetBufferSetLength(_MAX_EXT), _MAX_EXT);
#else
_tsplitpath(path, m_drive.GetBufferSetLength(_MAX_DRIVE),
m_dir.GetBufferSetLength(_MAX_DIR),
m_file.GetBufferSetLength(_MAX_FNAME),
m_ext.GetBufferSetLength(_MAX_EXT));
#endif
m_ext.ReleaseBuffer();
m_file.ReleaseBuffer();
m_dir.ReleaseBuffer();
m_drive.ReleaseBuffer();
}
void CDosPath::SetPath(const TCHAR *pszPath, int nFlags)
{
if (nFlags & PATH_ONLY)
{
CString temp(pszPath);
temp += '\\';
SplitPath(temp);
}
else
SplitPath(pszPath);
}
CDosPath &CDosPath::operator|=(CDosPath &fullpath)
{
if (m_drive.IsEmpty())
{
// TRACE1("Inserting drive %s\n", fullpath.m_szDrive);
m_drive = fullpath.m_drive;
}
if (m_dir.IsEmpty())
{
// TRACE1("Inserting directory %s\n", fullpath.m_szDir);
m_dir = fullpath.m_dir;
}
if (m_file.IsEmpty())
{
// TRACE1("Inserting file %s\n", fullpath.m_szFile);
m_file = fullpath.m_file;
}
if (m_ext.IsEmpty())
{
// TRACE1("Inserting extension %s\n", fullpath.m_szExt);
m_ext = fullpath.m_ext;
}
return *this;
}
CDosPath CDosPath::operator|(CDosPath &fullpath)
{
CDosPath temp(GetPath());
temp |= fullpath;
return temp;
}
CString CDosPath::GetPath() const
{
CString temp;
#if USE_SECURE
_tmakepath_s(temp.GetBufferSetLength(_MAX_PATH), _MAX_PATH, m_drive, m_dir, m_file, m_ext);
#else
_tmakepath(temp.GetBufferSetLength(_MAX_PATH), m_drive, m_dir, m_file, m_ext);
#endif
temp.ReleaseBuffer();
return temp;
}
CString CDosPath::GetPathOnly() const
{
CString temp;
#if USE_SECURE
_tmakepath_s(temp.GetBufferSetLength(_MAX_PATH), _MAX_PATH, m_drive, m_dir, NULL, NULL);
#else
_tmakepath(temp.GetBufferSetLength(_MAX_PATH), m_drive, m_dir, NULL, NULL);
#endif
temp.ReleaseBuffer();
return temp;
}
CDosPath CDosPath::CurrentPath()
{
TCHAR szBuffer[_MAX_PATH];
_tgetcwd(szBuffer, _MAX_PATH);
return CDosPath(szBuffer, PATH_ONLY);
}
CDosPath CDosPath::AppPath()
{
TCHAR szBuffer[_MAX_PATH];
#ifdef _MFC
GetModuleFileName(AfxGetApp()->m_hInstance, szBuffer, _MAX_PATH);
#else
GetModuleFileName(GetModuleHandle(NULL), szBuffer, _MAX_PATH);
#endif
return CDosPath(szBuffer);
}
CDosPath CDosPath::WindowsPath()
{
TCHAR szBuffer[_MAX_PATH];
GetWindowsDirectory(szBuffer, _MAX_PATH);
return CDosPath(szBuffer, PATH_ONLY);
}
#ifdef MAKE_EXE
#include <stdio.h>
void main(int ac, char *av[])
{
if (ac != 3)
{
printf("Usage: dospath incomplete complete\n");
return;
}
CDosPath a = av[1];
CDosPath b = av[2];
a |= b;
printf("%s |= %s = %s\n", av[1], av[2], (const char *) a.GetPath());
printf("\n\n\n\n");
a = CDosPath::CurrentPath();
printf("Current = %s\n", (const char *)a.GetPath());
a = CDosPath::AppPath();
printf("App = %s\n", (const char *)a.GetPath());
a = CDosPath::TempPath();
printf("Temp = %s\n", (const char *)a.GetPath());
}
#endif

View File

@ -1,51 +0,0 @@
/*
* (C) 1997, 2006 Mike Crowe
*
* License: Do what you like with it except claim that you wrote it.
*/
#ifndef DOSPATH_H
#define DOSPATH_H
class CDosPath
{
CString m_drive;
CString m_dir;
CString m_file;
CString m_ext;
void SplitPath(const TCHAR *buffer);
public:
enum { PATH_ONLY = 1 };
CDosPath(const TCHAR *pszPath, int nFlags = 0);
CDosPath(const CDosPath &old);
~CDosPath();
CDosPath &operator|=(CDosPath &fullpath);
CDosPath operator|(CDosPath &fullpath);
CDosPath &operator=(const CDosPath &old);
CString GetPath() const;
CString GetPathOnly() const;
void SetPath(const TCHAR *pszBuffer, int nFlags = 0);
static CDosPath CurrentPath();
static CDosPath AppPath();
static CDosPath TempPath();
#ifdef _WINDOWS
static CDosPath WindowsPath();
#endif
CString GetFile()
{
return m_file;
}
CString GetExt()
{
return m_ext;
}
};
#endif // DOSPATH_H

View File

@ -1,394 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include <winnls.h>
#include "resource.h"
#include "FireflyShell.h"
#include "DosPath.h"
#include "ServiceControl.h"
#include "MainDlg.h"
#include "ServerEvents.h"
#include "IniFile.h"
CAppModule _Module;
#define RUN_KEY _T("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run")
#define RUN_VALUE _T("FireflyShell")
Application::Application()
: m_dlg(NULL), m_server_events(&m_icon)
{
CDosPath path = CDosPath::AppPath();
SetCurrentDirectory(path.GetPathOnly());
CDosPath filename(_T("mt-daapd.conf"));
filename |= path;
m_config_path = filename.GetPath();
ATLTRACE("Config path: %s\n", (const TCHAR *)m_config_path);
// Dump an ini file with drive mappings
CDosPath mapfile(_T("mapping.ini"));
mapfile |= path;
m_ini_path = mapfile.GetPath();
/* Load the proper language dll, if possible */
LANGID lidDefault = GetUserDefaultLangID();
int iBaseLanguage = lidDefault & 0xFF;
iBaseLanguage = GetPrivateProfileInt(_T("shell"),_T("lang_id"),iBaseLanguage,m_ini_path);
TCHAR tempPath[24];
wsprintf(tempPath,_T("FireflyShell-%02x.dll"),iBaseLanguage);
CDosPath langlib(tempPath);
langlib |= path;
HMODULE hLangDLL;
if((hLangDLL=LoadLibrary(langlib.GetPath())) != NULL) {
_AtlBaseModule.SetResourceInstance(hLangDLL);
}
TCHAR inbuffer[4];
TCHAR outbuffer[2048]; /* as max_path is unreliable */
DWORD size;
UNIVERSAL_NAME_INFO * puni = (UNIVERSAL_NAME_INFO *) &outbuffer;
for(int x='A'; x<='Z'; x++) {
wsprintf(inbuffer,_T("%c:\\"),x);
memset(outbuffer,0,sizeof(outbuffer));
size = sizeof(outbuffer);
WNetGetUniversalName(inbuffer,UNIVERSAL_NAME_INFO_LEVEL,outbuffer,
&size);
wsprintf(inbuffer,_T("%c"),x);
WritePrivateProfileString(_T("mapping"),inbuffer,puni->lpUniversalName,
mapfile.GetPath());
}
// We don't care if this fails. We can deal with that later.
m_service.Open(_T("Firefly Media Server"));
CheckCanConfigure();
m_unique_name = GenerateUniqueName();
m_registered_activation_message = ::RegisterWindowMessage(m_unique_name);
}
Application::~Application()
{
ATLASSERT(m_dlg == NULL);
}
void Application::CheckCanConfigure()
{
IniFile ini(m_config_path);
m_configurable = ini.IsWritable();
}
int Application::Run(LPCTSTR lpstrCmdLine, int nCmdShow)
{
if (ActivatePreviousInstance(lpstrCmdLine, nCmdShow))
{
ATLTRACE(_T("Already running\n"));
return 0;
}
CMessageLoop theLoop;
_Module.AddMessageLoop(&theLoop);
if (!m_icon.Create())
{
ATLTRACE(_T("Icon creation failed!\n"));
return 0;
}
EnableServerEvents(true);
if (ShowDialogAtStart(lpstrCmdLine, nCmdShow))
Configure(false);
int nRet = theLoop.Run();
EnableServerEvents(false);
m_icon.Destroy();
_Module.RemoveMessageLoop();
return nRet;
}
void Application::Exit()
{
if (m_dlg)
{
m_dlg->DestroyWindow();
}
::PostQuitMessage(0);
}
void Application::Configure(bool move_window)
{
if (m_dlg)
{
m_dlg->ShowWindow(SW_RESTORE);
SetForegroundWindow(m_dlg->m_hWnd);
}
else
{
CheckCanConfigure();
// Other people may need to talk to the dialog while it exists.
CMainDlg dlg(move_window);
m_dlg = &dlg;
dlg.DoModal();
m_dlg = NULL;
}
}
void Application::StartService(HWND hwndParent)
{
CWaitCursor wc;
ATLASSERT(m_service.CanControl());
if (!m_service.CanControl())
return;
if (!m_service.StartAndWait())
{
MessageBox(hwndParent, IDS_SERVERSTARTFAIL, MB_OK);
}
}
void Application::StopService(HWND hwndParent)
{
CWaitCursor wc;
ATLASSERT(m_service.CanControl());
if (!m_service.CanControl())
return;
if (!m_service.StopAndWait())
{
MessageBox(hwndParent, IDS_SERVERSTOPFAIL, MB_OK);
}
}
void Application::RestartService(HWND hwndParent)
{
CWaitCursor wc;
StopService(hwndParent);
StartService(hwndParent);
}
bool Application::ShowDialogAtStart(LPCTSTR cmdline, int nCmdShow)
{
if ((cmdline[0] == '-') && (cmdline[1] == 'q'))
return false;
switch (nCmdShow)
{
case SW_RESTORE:
case SW_SHOW:
case SW_SHOWMAXIMIZED:
case SW_SHOWNORMAL:
case SW_SHOWDEFAULT:
case SW_MAX:
return true;
default:
return false;
}
}
BOOL CALLBACK Application::StaticWindowSearcher(HWND hwnd, LPARAM lparam)
{
DWORD result;
LRESULT ok = ::SendMessageTimeout(hwnd,
static_cast<UINT>(lparam),
0, 0,
SMTO_BLOCK |
SMTO_ABORTIFHUNG,
200,
&result);
if (ok == 0)
return TRUE; // ignore this and continue
// If we get the magic response then we must have found our Window
// so we can give up.
if (result == lparam)
return FALSE;
else
return TRUE;
}
bool Application::ActivatePreviousInstance(LPCTSTR lpstrCmdLine, int nCmdShow)
{
HANDLE h = ::CreateMutex(NULL, TRUE, m_unique_name);
const bool running = (GetLastError() == ERROR_ALREADY_EXISTS);
if (h != NULL)
{
::ReleaseMutex(h);
}
// It seems that getting the other window to activate itself does
// actually work even though Windows anti-focus-stealing stuff
// could try and stop it.
if (running && ShowDialogAtStart(lpstrCmdLine, nCmdShow))
{
EnumWindows(StaticWindowSearcher, m_registered_activation_message);
return true;
}
return running;
}
CString Application::GenerateUniqueName()
{
// We need to allow one instance to run per desktop. See
// http://www.codeproject.com/cpp/avoidmultinstance.asp
// First start with some application unique
CString s(_T("Firefly-67A72768-4154-417e-BFA0-FA9B50C342DE"));
// Now append something desktop unique
DWORD len;
HDESK desktop = GetThreadDesktop(GetCurrentThreadId());
BOOL result = GetUserObjectInformation(desktop, UOI_NAME, NULL, 0, &len);
DWORD err = ::GetLastError();
if(!result && err == ERROR_INSUFFICIENT_BUFFER)
{ /* NT/2000/XP */
LPBYTE data = new BYTE[len];
result = GetUserObjectInformation(desktop, UOI_NAME, data, len, &len);
s += _T("-");
s += (LPCTSTR)data;
delete [ ] data;
} /* NT/2000/XP */
else
{ /* Win9x */
s += _T("-Win9x");
} /* Win9x */
return s;
}
void Application::EnableServerEvents(bool b)
{
if (b)
m_server_events.Start();
else
m_server_events.Stop();
}
CString Application::MakeRunKeyValue()
{
CString required_path("\"");
required_path += CDosPath::AppPath().GetPath();
required_path += "\" -q";
return required_path;
}
void Application::EnableServiceAutoStart(HWND hwnd, bool enable) {
int required_startup = enable ? SERVICE_AUTO_START : SERVICE_DEMAND_START;
if (m_service.GetStartup() != required_startup) {
if (!m_service.ConfigureStartup(required_startup)) {
MessageBox(hwnd, IDS_FAILED_CONFIGURE_SERVICE, MB_OK);
}
}
}
void Application::EnableAppletAutoStart(HWND hwnd, bool enable) {
HKEY hkey;
LONG result = ::RegOpenKeyEx(HKEY_CURRENT_USER, RUN_KEY, 0, KEY_SET_VALUE | STANDARD_RIGHTS_WRITE, &hkey);
if (result == ERROR_SUCCESS) {
if (enable) {
// We need to quote it because the path may contain spaces.
CString str = MakeRunKeyValue();
result = RegSetValueEx(hkey, RUN_VALUE, 0UL, REG_SZ, reinterpret_cast<LPCBYTE>(static_cast<LPCTSTR>(str)), (str.GetLength() + 1) * sizeof(TCHAR));
} else {
result = RegDeleteValue(hkey, RUN_VALUE);
if (result == ERROR_FILE_NOT_FOUND)
result = 0;
}
if (result != ERROR_SUCCESS) {
ATLTRACE("Error:%u\n", result);
MessageBox(hwnd, IDS_FAILED_CONFIGURE_STARTUP, MB_OK);
}
}
}
bool Application::IsServiceAutoStartEnabled() const {
return (m_service.GetStartup() == SERVICE_AUTO_START);
}
bool Application::IsAppletAutoStartEnabled() const {
bool run_result = false;
HKEY hkey;
if (::RegOpenKeyEx(HKEY_CURRENT_USER, RUN_KEY, 0, KEY_QUERY_VALUE | STANDARD_RIGHTS_READ, &hkey) == ERROR_SUCCESS)
{
DWORD dwType, cbData;
TCHAR buffer[_MAX_PATH + 1];
cbData = (_MAX_PATH + 1) * sizeof(TCHAR);
if (::RegQueryValueEx(hkey, RUN_VALUE, NULL, &dwType, reinterpret_cast<LPBYTE>(buffer), &cbData) == ERROR_SUCCESS)
{
CString path(buffer, cbData - sizeof(TCHAR));
ATLTRACE("Registry run key path: %s\n", (const TCHAR *)path);
if (path == MakeRunKeyValue())
run_result = true;
else
{
// It's there - but it isn't us that it will start.
// But from the user's perspective, it *is* us, so to make the perception
// match the setting, we'll make this true, rather than some indeterminate
// thing which nobody understands. -- Ron
run_result = true;
}
}
else
{
// The key doesn't exist.
run_result = false;
}
}
else
run_result = false;
return run_result;
}
int WINAPI _tWinMain(HINSTANCE hInstance, HINSTANCE /*hPrevInstance*/, LPTSTR lpstrCmdLine, int nCmdShow)
{
// this resolves ATL window thunking problem when Microsoft Layer for Unicode (MSLU) is used
::DefWindowProc(NULL, 0, 0, 0L);
AtlInitCommonControls(ICC_BAR_CLASSES); // add flags to support other controls
HRESULT hRes = _Module.Init(NULL, hInstance);
ATLASSERT(SUCCEEDED(hRes));
int nRet;
{
// Application object is destroyed prior to undoing everything above.
Application app;
nRet = app.Run(lpstrCmdLine, nCmdShow);
}
_Module.Term();
return nRet;
}

View File

@ -1,15 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<dependency>
<dependentAssembly>
<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="x86" publicKeyToken="6595b64144ccf1df" language="*"></assemblyIdentity>
</dependentAssembly>
</dependency>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level="asInvoker" />
</requestedPrivileges>
</security>
</trustInfo>
</assembly>

View File

@ -1,158 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef FIREFLYSHELL_H
#define FIREFLYSHELL_H 1
#include "singleton.h"
#include "NotifyIcon.h"
#include "ServiceControl.h"
#include <vector>
#include <algorithm>
#include "ServerEvents.h"
class CMainDlg;
/// The main application. Not a window.
class Application : public Singleton<Application>
{
CNotifyIcon m_icon;
CMainDlg *m_dlg;
CString m_config_path;
CString m_ini_path;
Service m_service;
ServiceStatusMonitor m_service_monitor;
ServerEvents m_server_events;
CString m_unique_name;
UINT m_registered_activation_message;
bool m_configurable;
/// Returns true if a previous instance was found. Only
/// actually activates a previous instance if nCmdShow
/// indicates so.
bool ActivatePreviousInstance(LPCTSTR cmdline, int nCmdShow);
/// Helper for ActivatePreviousInstance.
static BOOL CALLBACK Application::StaticWindowSearcher(HWND hwnd, LPARAM lparam);
/// Generate a unique name that can be used to detect multiple instances.
static CString GenerateUniqueName();
// Depending on how the application was launched we display the dialog or not.
static bool ShowDialogAtStart(LPCTSTR cmdline, int nCmdShow);
static CString MakeRunKeyValue();
public:
Application();
~Application();
/// Gets the application going
int Run(LPCTSTR lpstrCmdLine, int nCmdShow);
/// mt-daapd.conf path
CString GetConfigPath()
{
return m_config_path;
}
/// Registered message used to activate other instances
UINT GetRegisteredActivationMessage() const
{
return m_registered_activation_message;
}
// Pass true to move the window so it is near the mouse
// cursor.
void Configure(bool move_window);
void Exit();
// Service control
void StartService(HWND hwndParent);
void StopService(HWND hwndParent);
void RestartService(HWND hwndParent);
Service::Status GetServiceStatus()
{
Service::Status status;
if (m_service.IsOpen())
{
m_service.GetStatus(&status);
}
return status;
}
// Expensive - only do it just before displaying the dialog box.
void CheckCanConfigure();
// Cheap.
bool CanConfigure() const
{
// We need to both rewrite the config file and
// control the service if we're going to be
// useful.
return m_configurable && m_service.CanControl();
}
bool CanControlService() const
{
return m_service.CanControl();
}
void CheckServiceStatus()
{
m_service_monitor.Poll(&m_service);
}
void ServiceStatusSubscribe(ServiceStatusObserver *obs)
{
m_service_monitor.Subscribe(obs);
}
void ServiceStatusUnsubscribe(ServiceStatusObserver *obs)
{
m_service_monitor.Unsubscribe(obs);
}
CString GetServiceBinaryPath() const
{
return m_service.GetBinaryPath();
}
/// Used to disable listening for events from the server when this user is
/// not active.
void EnableServerEvents(bool);
/// Enable/disable automatic startup of service and FireflyShell.
void EnableAppletAutoStart(HWND, bool);
void EnableServiceAutoStart(HWND, bool);
/// Reports 0 for disabled, 1 for enabled
bool IsAppletAutoStartEnabled() const;
bool IsServiceAutoStartEnabled() const;
int MessageBox(HWND hwnd, UINT id, UINT flags)
{
CString title, text;
ATLVERIFY(title.LoadString(IDR_MAINFRAME));
ATLVERIFY(text.LoadString(id));
return ::MessageBox(hwnd, text, title, flags);
}
};
inline Application *GetApplication() { return Application::GetInstance(); }
#endif // FIREFLYSHELL_H

View File

@ -1,294 +0,0 @@
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "atlres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE
BEGIN
"#include ""atlres.h""\r\0"
END
3 TEXTINCLUDE
BEGIN
"#ifndef APSTUDIO_INVOKED\r\n"
"#include ""version.rc""\r\n"
"#endif // !APSTUDIO_INVOKED\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDR_MAINFRAME ICON "res\\FireflyShell.ico"
IDI_SHELL_RUNNING ICON "res\\shellrunning.ico"
IDI_SHELL_STOPPED ICON "res\\shellstopped.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDD_PAGE_ABOUT DIALOGEX 0, 0, 300, 228
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "About"
FONT 8, "MS Sans Serif", 0, 0, 0x0
BEGIN
CTEXT "For help, tips and troubleshooting advice...",IDC_FIREFLYLINK,12,92,276,9,NOT WS_GROUP
GROUPBOX "Version information",IDC_STATIC,6,121,288,100
CONTROL "",IDC_VERSIONLIST,"SysListView32",LVS_REPORT | LVS_ALIGNLEFT | WS_BORDER | WS_TABSTOP,12,132,276,68
PUSHBUTTON "&Copy to Clipboard",IDC_COPY,192,203,96,14
CONTROL 208,IDC_LOGO,"Static",SS_BITMAP | SS_CENTERIMAGE | SS_SUNKEN | WS_BORDER,6,7,288,73
CTEXT "For information on Firefly compatible music players...",IDC_ROKULINK,12,106,276,9,NOT WS_GROUP
END
IDD_PAGE_BASIC DIALOGEX 0, 0, 300, 230
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Library"
FONT 8, "MS Shell Dlg", 400, 0, 0x1
BEGIN
LTEXT "Library &Name",IDC_STATIC,12,24,74,8
EDITTEXT IDC_SERVERNAME,86,21,202,14,ES_AUTOHSCROLL
LTEXT "Media &Location",IDC_STATIC,12,61,74,8
EDITTEXT IDC_PATH,86,57,202,14,ES_AUTOHSCROLL
PUSHBUTTON "&Browse...",IDC_BROWSE,228,76,60,14
GROUPBOX "Security",IDC_STATIC,7,113,287,103
CONTROL "&Protect Firefly media library with a password",IDC_PROTECT,
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,12,135,276,10
LTEXT "Pass&word",IDC_STATIC,12,156,74,8
EDITTEXT IDC_PASSWORD,86,154,114,14,ES_PASSWORD | ES_AUTOHSCROLL
LTEXT "You can limit access to your music library by assigning a password. If a password is assigned, only clients that provide the correct password will be able to play music from your library.",IDC_STATIC,12,180,276,26,SS_NOPREFIX
END
IDD_PAGE_LOG DIALOGEX 0, 0, 300, 220
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Log"
FONT 8, "MS Shell Dlg", 400, 0, 0x1
BEGIN
EDITTEXT IDC_LOG,6,6,288,189,ES_MULTILINE | ES_AUTOHSCROLL | ES_READONLY | WS_VSCROLL | WS_HSCROLL
PUSHBUTTON "&Refresh",IDC_REFRESH,244,200,50,14
END
IDD_PAGE_ADVANCED DIALOGEX 0, 0, 300, 220
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Server"
FONT 8, "MS Shell Dlg", 400, 0, 0x1
BEGIN
GROUPBOX "Server Status",IDC_STATIC,6,7,288,82
LTEXT "Current state of the server goes here",IDC_SERVERSTATE,12,28,199,25
PUSHBUTTON "&Stop Server",IDC_STOPSERVICE,218,28,70,14
CONTROL "&Start Firefly when Windows starts",IDC_AUTOSTART,
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,12,59,252,10
CONTROL "&Enable Firefly icon in system tray",IDC_AUTOSTART_ICON,
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,12,73,252,10
GROUPBOX "Advanced",IDC_STATIC,6,93,288,61
LTEXT "Server port number",IDC_STATIC,12,108,99,11
EDITTEXT IDC_SERVERPORT,105,105,42,14,ES_AUTOHSCROLL | ES_NUMBER
CONTROL "",IDC_PORTSPIN,"msctls_updown32",UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | UDS_NOTHOUSANDS | UDS_HOTTRACK,146,105,11,14
LTEXT "You may need to change this if another program is already using this port.",IDC_STATIC,12,129,276,23
GROUPBOX "Web administration",IDC_STATIC,6,159,288,54
LTEXT "Firefly Media Server also provides a web administration interface.",IDC_STATIC,12,177,198,20
PUSHBUTTON "&Open",IDC_WEBADMIN,218,177,70,14
PUSHBUTTON "&Start Server",IDC_STARTSERVICE,218,28,70,14
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO
BEGIN
IDD_PAGE_ABOUT, DIALOG
BEGIN
LEFTMARGIN, 6
RIGHTMARGIN, 294
VERTGUIDE, 12
VERTGUIDE, 131
VERTGUIDE, 218
VERTGUIDE, 288
TOPMARGIN, 7
BOTTOMMARGIN, 221
END
IDD_PAGE_BASIC, DIALOG
BEGIN
LEFTMARGIN, 6
RIGHTMARGIN, 294
VERTGUIDE, 12
VERTGUIDE, 86
VERTGUIDE, 131
VERTGUIDE, 218
VERTGUIDE, 288
TOPMARGIN, 7
BOTTOMMARGIN, 216
END
IDD_PAGE_LOG, DIALOG
BEGIN
LEFTMARGIN, 6
RIGHTMARGIN, 294
VERTGUIDE, 6
VERTGUIDE, 12
VERTGUIDE, 216
VERTGUIDE, 288
HORZGUIDE, 6
HORZGUIDE, 214
END
IDD_PAGE_ADVANCED, DIALOG
BEGIN
LEFTMARGIN, 6
RIGHTMARGIN, 294
VERTGUIDE, 12
VERTGUIDE, 105
VERTGUIDE, 218
VERTGUIDE, 288
TOPMARGIN, 7
BOTTOMMARGIN, 216
END
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Accelerator
//
IDR_MAINFRAME ACCELERATORS
BEGIN
"N", ID_FILE_NEW, VIRTKEY, CONTROL
"O", ID_FILE_OPEN, VIRTKEY, CONTROL
"S", ID_FILE_SAVE, VIRTKEY, CONTROL
"P", ID_FILE_PRINT, VIRTKEY, CONTROL
"Z", ID_EDIT_UNDO, VIRTKEY, CONTROL
"X", ID_EDIT_CUT, VIRTKEY, CONTROL
"C", ID_EDIT_COPY, VIRTKEY, CONTROL
"V", ID_EDIT_PASTE, VIRTKEY, CONTROL
VK_BACK, ID_EDIT_UNDO, VIRTKEY, ALT
VK_DELETE, ID_EDIT_CUT, VIRTKEY, SHIFT
VK_INSERT, ID_EDIT_COPY, VIRTKEY, CONTROL
VK_INSERT, ID_EDIT_PASTE, VIRTKEY, SHIFT
VK_F6, ID_NEXT_PANE, VIRTKEY
VK_F6, ID_PREV_PANE, VIRTKEY, SHIFT
END
/////////////////////////////////////////////////////////////////////////////
//
// Menu
//
IDM_CONTEXT MENU
BEGIN
POPUP ""
BEGIN
MENUITEM "&Configure Firefly Media Server...", ID_CONFIGURE
MENUITEM "E&xit", ID_EXIT
END
END
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE
BEGIN
IDR_MAINFRAME "Firefly Media Server"
IDS_SERVER_RUNNING "The Firefly media server is currently running."
IDS_SERVER_STOPPED "The Firefly media server is not currently running."
IDS_SERVERSTARTFAIL "Failed to start Firefly Media Server."
IDS_SERVERSTOPFAIL "Failed to stop Firefly Media Server."
IDS_SERVER_PENDING "The Firefly media server is currently busy."
IDS_SERVER_START "&Start"
IDS_SERVER_STOP "&Stop"
IDS_SCAN_START "Scanning for media is in progress\n\nThis may take some time."
IDS_SCAN_STOP "Scanning for media is complete."
IDS_NOT_ADMIN "You must be logged in as a local administrator to start and stop the server."
IDS_QUERYSERVERRESTART "Changing the configuration will require a restart of the Firefly Media Server. Are you sure you want to do this?"
IDS_VERSIONINFO_DESCRIPTION "Description"
IDS_VERSIONINFO_VERSION "Version"
IDS_VERSIONINFO_PATH "Path"
IDS_FAILED_CONFIGURE_SERVICE "Failed to reconfigure service."
END
STRINGTABLE
BEGIN
IDS_FAILED_CONFIGURE_STARTUP "Failed to reconfigure startup application."
IDS_LOG_NOLOG "Firefly server logging is not enabled."
IDS_LOG_OPENFAILED "Failed to open server log file '%s'."
END
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
// English (U.K.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENG)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_UK
#pragma code_page(1252)
#endif //_WIN32
/////////////////////////////////////////////////////////////////////////////
//
// Bitmap
//
IDB_LOGO BITMAP "res\\logo.bmp"
#endif // English (U.K.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
#ifndef APSTUDIO_INVOKED
#include "version.rc"
#endif // !APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@ -1,339 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="FireflyShell"
ProjectGUID="{ED38F171-854B-4EA3-B3A0-7681648969FC}"
RootNamespace="FireflyShell"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="1"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="version.lib mpr.lib"
OutputFile="$(OutDir)/FireflyShell.exe"
LinkIncremental="2"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/FireflyShell.pdb"
SubSystem="2"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="1"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS"
RuntimeLibrary="2"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="version.lib mpr.lib"
OutputFile="$(OutDir)/FireflyShell.exe"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File
RelativePath=".\AboutPage.cpp"
>
</File>
<File
RelativePath=".\AdvancedPage.cpp"
>
</File>
<File
RelativePath=".\ConfigPage.cpp"
>
</File>
<File
RelativePath=".\DosPath.cpp"
>
</File>
<File
RelativePath=".\FireflyShell.cpp"
>
</File>
<File
RelativePath=".\LogPage.cpp"
>
</File>
<File
RelativePath=".\MainDlg.cpp"
>
</File>
<File
RelativePath=".\NotifyIcon.cpp"
>
</File>
<File
RelativePath=".\ServerEvents.cpp"
>
</File>
<File
RelativePath=".\ServiceControl.cpp"
>
</File>
<File
RelativePath=".\stdafx.cpp"
>
</File>
<File
RelativePath=".\VersionInfo.cpp"
>
</File>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
<File
RelativePath=".\AboutPage.h"
>
</File>
<File
RelativePath=".\AdvancedPage.h"
>
</File>
<File
RelativePath=".\ConfigPage.h"
>
</File>
<File
RelativePath=".\DosPath.h"
>
</File>
<File
RelativePath=".\FireflyShell.h"
>
</File>
<File
RelativePath=".\IniFile.h"
>
</File>
<File
RelativePath=".\LogPage.h"
>
</File>
<File
RelativePath=".\MainDlg.h"
>
</File>
<File
RelativePath=".\NotifyIcon.h"
>
</File>
<File
RelativePath=".\resource.h"
>
</File>
<File
RelativePath=".\ServerEvents.h"
>
</File>
<File
RelativePath=".\ServiceControl.h"
>
</File>
<File
RelativePath=".\singleton.h"
>
</File>
<File
RelativePath=".\stdafx.h"
>
</File>
<File
RelativePath=".\VersionInfo.h"
>
</File>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\res\FireflyShell.ico"
>
</File>
<File
RelativePath=".\FireflyShell.rc"
>
</File>
<File
RelativePath=".\res\logo.bmp"
>
</File>
<File
RelativePath=".\res\ShellRunning.ico"
>
</File>
<File
RelativePath=".\res\ShellStopped.ico"
>
</File>
</Filter>
<File
RelativePath=".\FireflyShell.exe.manifest"
>
</File>
<File
RelativePath=".\README.txt"
>
</File>
</Files>
<Globals>
<Global
Name="RESOURCE_FILE"
Value="FireflyShell.rc"
/>
</Globals>
</VisualStudioProject>

View File

@ -1,204 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="FireflyShellDEU"
ProjectGUID="{9B035724-EAD7-48C5-BBAF-91FFAA3CA55F}"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLDEU_EXPORTS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-07.dll"
LinkIncremental="2"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/FireflyShellDEU.pdb"
SubSystem="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellDEU.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLDEU_EXPORTS"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-07.dll"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellDEU.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\FireflyShell.DEU.rc"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -1,204 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="FireflyShellFRA"
ProjectGUID="{819028A4-ED43-4A51-9E32-DC8559ADEBB6}"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLFRA_EXPORTS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-0c.dll"
LinkIncremental="2"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/FireflyShellFRA.pdb"
SubSystem="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellFRA.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLFRA_EXPORTS"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-0c.dll"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellFRA.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\FireflyShellFRA.rc"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -1,204 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="FireflyShellITA"
ProjectGUID="{E8F129E2-CABC-4FCD-9A9E-CDE338F4B1D0}"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLITA_EXPORTS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-10.dll"
LinkIncremental="2"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/FireflyShellITA.pdb"
SubSystem="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellITA.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLITA_EXPORTS"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-10.dll"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellITA.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\FireflyShellITA.rc"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -1,204 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="FireflyShellJPN"
ProjectGUID="{59618041-38FA-4D80-B00B-113417259E6D}"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLJPN_EXPORTS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-11.dll"
LinkIncremental="2"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/FireflyShellJPN.pdb"
SubSystem="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellJPN.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLJPN_EXPORTS"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-11.dll"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellJPN.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\FireflyShellJPN.rc"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -1,204 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="FireflyShellNLD"
ProjectGUID="{5D6F19F6-6A71-4960-BFB3-BF545D02ACBD}"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLNLD_EXPORTS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-13.dll"
LinkIncremental="2"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/FireflyShellNLD.pdb"
SubSystem="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellNLD.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLNLD_EXPORTS"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-13.dll"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellNLD.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\FireflyShellNLD.rc"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -1,204 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="FireflyShellSWE"
ProjectGUID="{D8109A27-5CB3-4888-B62A-F83BB3B1D41F}"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLSWE_EXPORTS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-1d.dll"
LinkIncremental="2"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/FireflyShellSWE.pdb"
SubSystem="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellSWE.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;FIREFLYSHELLSWE_EXPORTS"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)/FireflyShell-1d.dll"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ResourceOnlyDLL="true"
ImportLibrary="$(OutDir)/FireflyShellSWE.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\FireflyShellSWE.rc"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -1,68 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef INIFILE_H
#define INIFILE_H
#include "DosPath.h"
class IniFile
{
CString m_path;
public:
explicit IniFile(const CString &path)
: m_path(path)
{
}
CString GetString(const TCHAR *section, const TCHAR *key, const TCHAR *defstring)
{
CString str;
::GetPrivateProfileString(section, key, defstring, str.GetBuffer(512), 512, m_path);
str.ReleaseBuffer();
return str;
}
bool SetString(const TCHAR *section, const TCHAR *key, const TCHAR *value)
{
return ::WritePrivateProfileString(section, key, value, m_path) != 0;
}
int GetInteger(const TCHAR *section, const TCHAR *key, int defvalue)
{
return ::GetPrivateProfileInt(section, key, defvalue, m_path);
}
bool SetInteger(const TCHAR *section, const TCHAR *key, int value)
{
CString str;
str.Format(_T("%d"), value);
return ::WritePrivateProfileString(section, key, str, m_path) != 0;
}
bool IsWritable() const
{
if (::WritePrivateProfileString(_T("Writability Test"), _T("Writability Test"), _T("Test"), m_path))
{
// Remove it then.
::WritePrivateProfileString(_T("Writability Test"), NULL, NULL, m_path);
return true;
}
else
return false;
}
};
#endif // INIFILE_H

View File

@ -1,109 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "LogPage.h"
#include "FireflyShell.h"
#include "IniFile.h"
LRESULT CLogPage::OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/)
{
LoadLog();
return 0;
}
LRESULT CLogPage::OnRefresh(WORD /*wNotifyCode*/, WORD /*wID*/, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
LoadLog();
return 0;
}
void CLogPage::LoadLog()
{
CWaitCursor wait;
const size_t MAX_LOG = 65000;
IniFile ini(GetApplication()->GetConfigPath());
CString filename = ini.GetString(_T("general"), _T("logfile"), _T(""));
if (filename.IsEmpty())
{
CString str;
str.LoadString(IDS_LOG_NOLOG);
GetDlgItem(IDC_LOG).SetWindowText(str);
}
else
{
FILE *fp = _tfopen(filename, _T("r"));
if (fp)
{
// Fathom the length
fseek(fp, 0, SEEK_END);
long len = ftell(fp);
if (len > MAX_LOG)
{
len = MAX_LOG;
fseek(fp, -len, SEEK_END);
}
else
{
fseek(fp, 0, SEEK_SET);
}
char *buffer = new char[len + 1];
size_t nread = fread(buffer, 1, len, fp);
ATLASSERT(nread < MAX_LOG);
buffer[nread] = 0;
fclose(fp);
// Normalise the line endings. Not particularly efficient but
// it does work. It would be nice if we could cheaply tell
// CString to preallocate a certain size.
CString log(_T("Log file: "));
log += filename;
log += _T("\r\n\r\n");
size_t n = 0;
while (n < nread)
{
switch (buffer[n])
{
case '\r':
// Ignore
break;
case '\n':
log += _T("\r\n");
break;
default:
log += buffer[n];
break;
}
++n;
}
GetDlgItem(IDC_LOG).SetWindowText(log);
delete []buffer;
}
else
{
CString str;
str.Format(IDS_LOG_OPENFAILED, filename);
GetDlgItem(IDC_LOG).SetWindowText(str);
}
}
}

View File

@ -1,46 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef LOGPAGE_H
#define LOGPAGE_H 1
#include "resource.h"
class CLogPage :
public CPropertyPageImpl<CLogPage>
{
typedef CPropertyPageImpl<CLogPage> base;
public:
enum { IDD = IDD_PAGE_LOG };
private:
// Message Handlers
BEGIN_MSG_MAP(CLogPage)
MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
COMMAND_HANDLER(IDC_REFRESH, BN_CLICKED, OnRefresh)
CHAIN_MSG_MAP(base)
END_MSG_MAP()
LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
LRESULT OnRefresh(WORD /*wNotifyCode*/, WORD /*wID*/, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
void LoadLog();
};
#endif // LOGPAGE_H

View File

@ -1,121 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "resource.h"
#include "MainDlg.h"
#include "FireflyShell.h"
CMainDlg::CMainDlg(bool move_window)
: m_window_move_required(move_window)
{
this->AddPage(m_pageConfig);
this->AddPage(m_pageAdvanced);
this->AddPage(m_pageLog);
this->AddPage(m_pageAbout);
ATLVERIFY(m_strTitle.LoadString(IDR_MAINFRAME));
this->SetTitle(m_strTitle);
}
void CMainDlg::OnSheetInitialized()
{
HICON hIcon = (HICON)::LoadImage(_Module.GetResourceInstance(), MAKEINTRESOURCE(IDR_MAINFRAME),
IMAGE_ICON, ::GetSystemMetrics(SM_CXICON), ::GetSystemMetrics(SM_CYICON), LR_DEFAULTCOLOR);
SetIcon(hIcon, TRUE);
HICON hIconSmall = (HICON)::LoadImage(_Module.GetResourceInstance(), MAKEINTRESOURCE(IDR_MAINFRAME),
IMAGE_ICON, ::GetSystemMetrics(SM_CXSMICON), ::GetSystemMetrics(SM_CYSMICON), LR_DEFAULTCOLOR);
SetIcon(hIconSmall, FALSE);
}
LRESULT CMainDlg::OnCommand(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
{
bool restart_service = false;
if (HIWORD(wParam) == BN_CLICKED)
{
const UINT id = LOWORD(wParam);
if ((id == IDOK || id == ID_APPLY_NOW)
&& GetDlgItem(ID_APPLY_NOW).IsWindowEnabled()
&& GetApplication()->GetServiceStatus().IsRunning())
{
CString title, text;
title.LoadString(IDR_MAINFRAME);
text.LoadString(IDS_QUERYSERVERRESTART);
if (MessageBox(text, title, MB_YESNO) != IDYES)
return 0;
restart_service = true;
}
}
LRESULT result = base::OnCommand(uMsg, wParam, lParam, bHandled);
if (restart_service)
GetApplication()->RestartService(m_hWnd);
return result;
}
void CMainDlg::PositionWindow()
{
POINT cursor_pt;
GetCursorPos(&cursor_pt);
CRect desktop_rect;
if (SystemParametersInfo(SPI_GETWORKAREA, 0, &desktop_rect, 0))
{
// Don't put it hard against the edge of the screen or task bar.
desktop_rect.DeflateRect(CSize(4, 4));
CRect window_rect;
GetWindowRect(&window_rect);
// First move the window so that it's middle is at the cursor position.
CPoint pos;
pos.x = cursor_pt.x - window_rect.Width()/2;
pos.y = cursor_pt.y - window_rect.Height()/2;
// Now make that window appear on the work area but in case it doesn't fit prefer to fit the
// top left.
if (pos.x + window_rect.Width() > desktop_rect.right)
pos.x = desktop_rect.right - window_rect.Width();
if (pos.y + window_rect.Height() > desktop_rect.bottom)
pos.y = desktop_rect.bottom - window_rect.Height();
if (pos.x < desktop_rect.left)
pos.x = desktop_rect.left;
if (pos.y < desktop_rect.top)
pos.y = desktop_rect.top;
SetWindowPos(NULL, pos.x, pos.y, 0, 0, SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOZORDER);
}
}
void CMainDlg::OnMove(CPoint pt)
{
if (m_window_move_required)
{
// We don't want to recurse.
m_window_move_required = false;
PositionWindow();
}
else
{
SetMsgHandled(false);
}
}

View File

@ -1,56 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef MAINDLG_H
#define MAINDLG_H 1
#include "ConfigPage.h"
#include "AdvancedPage.h"
#include "LogPage.h"
#include "AboutPage.h"
class CMainDlg : public CPropertySheetImpl<CMainDlg>
{
typedef CPropertySheetImpl<CMainDlg> base;
CString m_strTitle;
CConfigPage m_pageConfig;
CAdvancedPage m_pageAdvanced;
CLogPage m_pageLog;
CAboutPage m_pageAbout;
bool m_window_move_required;
BEGIN_MSG_MAP(CMainDlg)
MESSAGE_HANDLER(WM_COMMAND, OnCommand)
MSG_WM_MOVE(OnMove)
CHAIN_MSG_MAP(base)
END_MSG_MAP()
LRESULT OnCommand(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled);
void OnMove(CPoint);
void PositionWindow();
void OnSheetInitialized();
public:
// Pass true if you want the window to be moved to near the mouse pointer.
// This is usually only the case if the window is displayed as a result of
// clicking on the shell notification icon.
CMainDlg(bool move_window);
};
#endif // MAINDLG_H

View File

@ -1,296 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "resource.h"
#include "NotifyIcon.h"
#include "FireflyShell.h"
CNotifyMsg::CNotifyMsg(UINT32 id, UINT32 intval, const CString &strval) {
this->id = id;
this->intval = intval;
this->strval = strval;
}
CNotifyIcon::CNotifyIcon()
{
ZeroMemory(&m_nid, sizeof(NOTIFYICONDATA));
m_nid.cbSize = sizeof(NOTIFYICONDATA);
m_nid.uID = ID_SHELLNOTIFY;
m_running_icon = AtlLoadIcon(IDI_SHELL_RUNNING);
m_stopped_icon = AtlLoadIcon(IDI_SHELL_STOPPED);
}
BOOL CNotifyIcon::Create()
{
m_registered_activation_message = GetApplication()->GetRegisteredActivationMessage();
RECT rect = {0, 0, 0, 0};
// Hidden window.
if (base::Create(NULL, rect, _T("FireflyShellNotifyIconHidden"), WS_POPUP))
{
m_nid.uFlags = NIF_ICON|NIF_MESSAGE|NIF_TIP;
InflictIconState();
//wcsncpy(niData.szTip, TEXT("Foo?"), sizeof(niData.szTip));
m_nid.hWnd = m_hWnd;
m_nid.uCallbackMessage = PRIVATE_WM_NOTIFYICON;
Shell_NotifyIcon(NIM_ADD, &m_nid);
SetTimer(TIMER_ID, 5000, NULL);
GetApplication()->ServiceStatusSubscribe(this);
EnableUserSwitchNotifications();
return TRUE;
}
return FALSE;
}
void CNotifyIcon::Destroy()
{
GetApplication()->ServiceStatusUnsubscribe(this);
KillTimer(TIMER_ID);
Shell_NotifyIcon(NIM_DELETE, &m_nid);
DestroyIcon(m_nid.hIcon);
base::DestroyWindow();
}
void CNotifyIcon::OnClose()
{
// The only time this should happen is if something else explicitly
// sends us the message (such as the installer). We'll just
// exit completely.
GetApplication()->Exit();
}
void CNotifyIcon::PopupBalloon(CString &title, CString &text, DWORD flags) {
m_nid.uFlags |= NIF_INFO;
SafeStringCopy(m_nid.szInfoTitle, title, 64);
SafeStringCopy(m_nid.szInfo,text, 256);
m_nid.dwInfoFlags = flags;
m_nid.uTimeout = 10000;
Shell_NotifyIcon(NIM_MODIFY, &m_nid);
}
void CNotifyIcon::PopupBalloon(UINT title_id, UINT text_id, DWORD flags) {
CString title, text;
title.LoadString(title_id);
text.LoadString(text_id);
PopupBalloon(title, text, flags);
}
void CNotifyIcon::Update()
{
InflictIconState();
// I suspect we'll need this line too.
// m_nid.uFlags &= ~NIF_INFO;
Shell_NotifyIcon(NIM_MODIFY, &m_nid);
}
void CNotifyIcon::InflictIconState()
{
// Will the icons leak?
Service::Status status = GetApplication()->GetServiceStatus();
UINT state_id;
if (status.IsPending())
{
state_id = IDS_SERVER_PENDING;
m_nid.hIcon = m_stopped_icon; // As good as any?
}
else if (status.IsRunning())
{
state_id = IDS_SERVER_RUNNING;
m_nid.hIcon = m_running_icon;
}
else
{
state_id = IDS_SERVER_STOPPED;
m_nid.hIcon = m_stopped_icon;
}
CString tip;
tip.LoadString(state_id);
SafeStringCopy(m_nid.szTip, tip, 64);
}
void CNotifyIcon::OnServiceStatus(Service::Status old_status, Service::Status new_status)
{
Update();
}
void CNotifyIcon::OnTimer(UINT id, TIMERPROC proc)
{
if (id == TIMER_ID)
{
GetApplication()->CheckServiceStatus();
}
}
LRESULT CNotifyIcon::OnNotifyIconMessage(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
{
switch (lParam)
{
case WM_LBUTTONDBLCLK:
GetApplication()->Configure(true);
bHandled = true;
return 0L;
case WM_RBUTTONDOWN:
case WM_CONTEXTMENU:
OnContextMenu();
bHandled = true;
return 0L;
}
return 0L;
}
void CNotifyIcon::OnContextMenu()
{
HMENU hMenu;
HINSTANCE hInstance = _Module.GetResourceInstance();
hMenu = ::LoadMenu(hInstance, MAKEINTRESOURCE(IDM_CONTEXT));
POINT pt;
GetCursorPos(&pt);
// See TrackPopupMenu in MSDN.
SetForegroundWindow(m_hWnd);
//::SetForegroundWindow(m_hWnd);
HMENU hPopup = GetSubMenu(hMenu, 0);
::SetMenuDefaultItem(hPopup, ID_CONFIGURE, FALSE);
TrackPopupMenu(hPopup, TPM_LEFTALIGN | TPM_BOTTOMALIGN, pt.x, pt.y, 0, m_hWnd, NULL);
::PostMessage(m_hWnd, WM_NULL, 0, 0);
::DestroyMenu(hMenu);
}
LRESULT CNotifyIcon::OnConfigure(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
GetApplication()->Configure(true);
return 0;
}
LRESULT CNotifyIcon::OnExit(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
/// @todo
Application::GetInstance()->Exit();
return 0;
}
LRESULT CNotifyIcon::OnRegisteredActivation(UINT, WPARAM, LPARAM, BOOL &bHandled)
{
ATLTRACE(_T("Activate\n"));
bHandled = true;
GetApplication()->Configure(false);
// We return a magic number so that the caller knows we've been found
// and can give up.
return m_registered_activation_message;
}
void CNotifyIcon::OnServerEvent(UINT32 id, UINT32 intval, const CString &strval) {
// Note that we're running on a different thread here. We need to punt
// the event over to the main thread using SendMessage.
CNotifyMsg *pMsgNew = new CNotifyMsg(id, intval,strval);
switch (id) {
case 0:
case 1:
case 2:
SendMessage(WM_SERVEREVENT, id, (LPARAM) pMsgNew);
break;
default:
ATLASSERT(false);
break;
}
}
LRESULT CNotifyIcon::OnServerEvent(UINT, WPARAM wparam, LPARAM lparam, BOOL &bHandled) {
CNotifyMsg *pMsgNotify = (CNotifyMsg *)lparam;
bHandled = true;
CString title;
title.LoadString(IDR_MAINFRAME);
// CString title, text;
// title.LoadString(title_id);
switch (wparam) {
case 0:
if(pMsgNotify->GetIntval() == 0)
PopupBalloon(title,pMsgNotify->GetStrval());
break;
case 1:
PopupBalloon(IDR_MAINFRAME, IDS_SCAN_START);
break;
case 2:
PopupBalloon(IDR_MAINFRAME, IDS_SCAN_STOP);
break;
}
delete(pMsgNotify);
return 0;
}
void CNotifyIcon::EnableUserSwitchNotifications()
{
HMODULE h = ::LoadLibrary(_T("WtsApi32.dll"));
if (h)
{
typedef BOOL (WINAPI *Proc)(HWND, DWORD);
Proc fn = reinterpret_cast<Proc>(GetProcAddress(h, "WTSRegisterSessionNotification"));
if (fn)
{
(*fn)(m_hWnd, NOTIFY_FOR_THIS_SESSION);
}
::FreeLibrary(h);
}
}
LRESULT CNotifyIcon::OnSessionChange(UINT, WPARAM wparam, LPARAM, BOOL &bHandled)
{
// Because only one process can get events through the mailslot we
// disconnect from it when the user uses XP fast user switching to
// switch to a different user.
switch (wparam)
{
case WTS_CONSOLE_CONNECT:
case WTS_REMOTE_CONNECT:
ATLTRACE("SESSION CONNECT\n");
GetApplication()->EnableServerEvents(true);
break;
case WTS_CONSOLE_DISCONNECT:
case WTS_REMOTE_DISCONNECT:
ATLTRACE("SESSION DISCONNECT\n");
GetApplication()->EnableServerEvents(false);
break;
}
bHandled = true;
return 0;
}

View File

@ -1,96 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef NOTIFYICON_H
#define NOTIFYICON_H
#include "ServiceControl.h"
#include "ServerEvents.h"
class CNotifyMsg {
UINT32 id;
UINT32 intval;
CString strval;
public:
CNotifyMsg(UINT32 id, UINT32 intval, const CString &strval);
CString &GetStrval(void) { return strval; };
UINT32 GetIntval(void) { return intval; };
};
class CNotifyIcon
: public CWindowImpl<CNotifyIcon>,
public ServiceStatusObserver,
public ServerEvents::Observer
{
typedef CWindowImpl<CNotifyIcon> base;
NOTIFYICONDATA m_nid;
HICON m_running_icon;
HICON m_stopped_icon;
UINT m_registered_activation_message;
enum { TIMER_ID = 43 };
enum { WM_SERVEREVENT = WM_APP + 42 };
enum { PRIVATE_WM_NOTIFYICON = WM_USER + 42 };
BEGIN_MSG_MAP(CNotifyIcon)
MESSAGE_HANDLER(PRIVATE_WM_NOTIFYICON, OnNotifyIconMessage)
COMMAND_ID_HANDLER(ID_CONFIGURE, OnConfigure)
COMMAND_ID_HANDLER(ID_EXIT, OnExit)
MESSAGE_HANDLER(m_registered_activation_message, OnRegisteredActivation)
MESSAGE_HANDLER(WM_SERVEREVENT, OnServerEvent)
MESSAGE_HANDLER(WM_WTSSESSION_CHANGE, OnSessionChange)
MSG_WM_TIMER(OnTimer)
MSG_WM_CLOSE(OnClose)
END_MSG_MAP()
// Message handlers
void OnContextMenu();
LRESULT OnNotifyIconMessage(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
LRESULT OnConfigure(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
LRESULT OnExit(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/);
LRESULT OnRegisteredActivation(UINT, WPARAM, LPARAM, BOOL &bHandled);
LRESULT OnServerEvent(UINT, WPARAM, LPARAM, BOOL &bHandled);
LRESULT OnSessionChange(UINT, WPARAM, LPARAM, BOOL &bHandled);
void OnTimer(UINT id, TIMERPROC proc);
void OnClose();
void PopupBalloon(UINT title_id, UINT text_id, DWORD flags = NIIF_INFO);
void PopupBalloon(CString &title, CString &text, DWORD flags = NIIF_INFO);
void InflictIconState();
void Update();
// Terminal services stuff on XP.
void EnableUserSwitchNotifications();
// ServiceStatusObserver
void OnServiceStatus(Service::Status old_status, Service::Status new_status);
// ServerEvents::Observer
void OnServerEvent(UINT32 id, UINT32 intval, const CString &str);
public:
CNotifyIcon();
BOOL Create();
void Destroy();
};
#endif // NOTIFYICON_H

View File

@ -1,17 +0,0 @@
The FireflyShell source code is distributed under the terms of the GNU
General Public License Version 2 as published by the Free Software
Foundation. You can find a copy of this license in the
admin-root/gpl-license.txt file.
This program uses the Microsoft Windows Template Library which is released
under the Common Public License. The copyright holders of FireflyShell
explicitly grant the additional right to distribute binaries produced from
source code derived from FireflyShell that are linked with the Microsoft
Windows Template Library.
Note that you may not be able to incorporate third party GNU General Public
Licensed code into FireflyShell and then distribute binaries unless you have
a similar additional right from the copyright holder.
You can find the Windows Template Library at
http://sourceforge.net/projects/wtl/

View File

@ -1,142 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "ServerEvents.h"
ServerEvents::ServerEvents(Observer *obs) :
m_thread(INVALID_HANDLE_VALUE),
m_mailslot(INVALID_HANDLE_VALUE),
m_obs(obs)
{
}
ServerEvents::~ServerEvents()
{
ATLASSERT(m_mailslot == INVALID_HANDLE_VALUE);
ATLASSERT(m_thread == INVALID_HANDLE_VALUE);
}
bool ServerEvents::Start()
{
ATLASSERT(m_mailslot == INVALID_HANDLE_VALUE);
ATLASSERT(m_thread == INVALID_HANDLE_VALUE);
ATLASSERT(m_obs != NULL);
m_mailslot = ::CreateMailslot(_T("\\\\.\\mailslot\\FireflyMediaServer--67A72768-4154-417e-BFA0-FA9B50C342DE"), 0, MAILSLOT_WAIT_FOREVER, NULL);
if (m_mailslot != INVALID_HANDLE_VALUE)
{
//m_thread = ::CreateThread(NULL, 0, &StaticThreadProc, this, 0, &thread_id);
m_thread = (HANDLE)_beginthreadex(NULL, 0, &StaticThreadProc, this, 0, NULL);
if (m_thread == NULL)
{
// Failed
ATLTRACE("beginthreadex failed: %d\n", errno);
::CloseHandle(m_mailslot);
m_mailslot = INVALID_HANDLE_VALUE;
return false;
}
}
else
{
return false;
}
return true;
}
void ServerEvents::Stop()
{
ATLASSERT(m_mailslot != INVALID_HANDLE_VALUE);
ATLASSERT(m_thread != INVALID_HANDLE_VALUE);
// Force the thread to give up. This could be done with a separate event
// and overlapped IO but this is cheap.
CloseHandle(m_mailslot);
m_mailslot = INVALID_HANDLE_VALUE;
// Wait for it to finish.
WaitForSingleObject(m_thread, INFINITE);
CloseHandle(m_thread);
m_thread = INVALID_HANDLE_VALUE;
}
//DWORD ServerEvents::StaticThreadProc(LPVOID param)
unsigned ServerEvents::StaticThreadProc(void *param)
{
return reinterpret_cast<ServerEvents *>(param)->ThreadProc();
}
DWORD ServerEvents::ThreadProc()
{
const size_t BUFFER_SIZE = 65536;
void *buffer = operator new(BUFFER_SIZE);
bool finished = false;
while (!finished)
{
DWORD bytes_read;
if (ReadFile(m_mailslot, buffer, BUFFER_SIZE, &bytes_read, NULL))
{
TCHAR *b = (TCHAR *)buffer;
b[bytes_read/sizeof(TCHAR)] = 0;
ATLTRACE("%ls\n", b);
OnEvent(buffer, bytes_read);
}
else
{
ATLTRACE("Read failed: error %d\n", GetLastError());
finished = true;
}
}
return 0;
}
void ServerEvents::OnEvent(const void *buffer, size_t bytes_received)
{
const BYTE *received = reinterpret_cast<const BYTE *>(buffer);
if (bytes_received >= 12)
{
UINT32 packet_size = received[0] | (received[1] << 8) | (received[2] << 16) | (received[3] << 24);
UINT32 id = received[4] | (received[5] << 8) | (received[6] << 16) | (received[7] << 24);
UINT32 intval = received[8] | (received[9] << 8) | (received[10] << 16) | (received[11] << 24);
int string_length = static_cast<int>(bytes_received) - 12;
if ((packet_size < bytes_received) && (packet_size >= 12))
string_length = packet_size - 12;
CString str;
if (string_length > 0)
{
#ifdef UNICODE
// It might be less that string_length long after conversion but it shouldn't be more unless
// our codepage is extremely weird.
str.ReleaseBuffer(MultiByteToWideChar(CP_ACP, MB_PRECOMPOSED, reinterpret_cast<const char *>(received + 12),
string_length, str.GetBufferSetLength(string_length), string_length));
#else
SafeStringCopy(str.GetBufferSetLength(string_length), received + 12, string_length);
#endif
str.ReleaseBuffer(string_length);
}
m_obs->OnServerEvent(id, intval, str);
}
}

View File

@ -1,55 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef SERVEREVENTS_H
#define SERVEREVENTS_H
class ServerEvents
{
public:
/// Note that the observer is called on the wrong thread.
class Observer
{
public:
virtual void OnServerEvent(UINT32 id, UINT32 intval, const CString &str) = 0;
};
private:
HANDLE m_thread;
HANDLE m_mailslot;
Observer *m_obs;
static unsigned __stdcall StaticThreadProc(void *);
DWORD ThreadProc();
void OnEvent(const void *buffer, size_t length);
public:
ServerEvents(Observer *obs);
~ServerEvents();
void SetObserver(Observer *obs)
{
ATLASSERT(m_obs == NULL);
m_obs = obs;
}
bool Start();
void Stop();
};
#endif // SERVICE

View File

@ -1,250 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "ServiceControl.h"
#include "DosPath.h"
bool Service::ExecHelper(const TCHAR *szAction) {
SHELLEXECUTEINFO si;
ZeroMemory(&si,sizeof(si));
si.cbSize = sizeof(si);
si.fMask = SEE_MASK_FLAG_NO_UI | SEE_MASK_NOCLOSEPROCESS;
si.hwnd = NULL;
si.lpVerb = _T("open");
CDosPath path = CDosPath::AppPath();
CString strPath = path.GetPathOnly();
si.lpDirectory = static_cast<LPCTSTR>(strPath);
CDosPath filename = CDosPath(_T("svcctrl.exe"));
filename |= path;
CString strFilename = filename.GetPath();
si.lpFile = static_cast<LPCTSTR>(strFilename);
CString strParams;
strParams.Format(_T("%s \"%s\""),szAction,m_name);
si.lpParameters = static_cast<LPCTSTR>(strParams);
si.nShow = 0;
if(!ShellExecuteEx(&si))
return false;
WaitForSingleObject(si.hProcess, INFINITE);
DWORD dwResult;
GetExitCodeProcess(si.hProcess,&dwResult);
if(dwResult)
return false;
return true;
}
bool Service::Open(const TCHAR *name)
{
Close();
const DWORD USER_ACCESS = SC_MANAGER_CONNECT | SC_MANAGER_ENUMERATE_SERVICE | STANDARD_RIGHTS_READ;
DWORD dwDesiredAccess = USER_ACCESS;
m_sc_manager = ::OpenSCManager(NULL, SERVICES_ACTIVE_DATABASE, dwDesiredAccess);
if (!m_sc_manager)
m_can_control = false;
else
m_can_control = true;
if (m_sc_manager) {
m_sc_service = ::OpenService(m_sc_manager, name, dwDesiredAccess);
if (m_sc_service) {
m_name = name;
return true;
}
}
Close();
return false;
}
void Service::Close() {
if (m_sc_service) {
::CloseServiceHandle(m_sc_service);
m_sc_service = NULL;
}
if (m_sc_manager) {
::CloseServiceHandle(m_sc_manager);
m_sc_manager = NULL;
}
}
bool Service::GetStatus(Status *status) const
{
if (::QueryServiceStatus(m_sc_service, status))
return true;
else
return false;
}
bool Service::Start()
{
if (ExecHelper(_T("start")))
return true;
else
return false;
}
bool Service::StartAndWait()
{
if (Start())
{
Status status;
return WaitPending(&status, SERVICE_START_PENDING);
}
else
return false;
}
bool Service::Stop()
{
Status status;
if (ExecHelper(_T("stop")))
return true;
else
return false;
}
bool Service::StopAndWait()
{
Status status;
if (Stop())
return WaitPending(&status, SERVICE_STOP_PENDING);
else
return false;
}
bool Service::WaitPending(Status *status, DWORD existing_state)
{
ATLTRACE(_T("Enter Service::WaitPending\n"));
if (GetStatus(status))
{
DWORD dwStartTickCount = GetTickCount();
DWORD dwOldCheckPoint = status->dwCheckPoint;
while (status->dwCurrentState == existing_state)
{
ATLTRACE(_T("Service::WaitPending in loop\n"));
DWORD dwWaitTime = status->dwWaitHint / 10;
if (dwWaitTime < 1000)
dwWaitTime = 1000;
else if (dwWaitTime > 10000)
dwWaitTime = 10000;
ATLTRACE(_T("Sleeping\n"));
::Sleep(dwWaitTime);
if (!GetStatus(status))
{
ATLTRACE(_T("Service::WaitPending - Failed to get status\n"));
return false;
}
// If we haven't changed state yet then check to see that the
// service is actually making progress.
if (status->dwCurrentState == existing_state)
{
if (status->dwCheckPoint != dwOldCheckPoint)
{
// The service is making progress
dwStartTickCount = GetTickCount();
dwOldCheckPoint = status->dwCheckPoint;
}
else if (GetTickCount() - dwStartTickCount > status->dwWaitHint)
{
ATLTRACE(_T("Service::WaitPending - No progress\n"));
/// Hmm. No progress
return false;
}
}
}
}
ATLTRACE(_T("Service::WaitPending success\n"));
return true;
}
CString Service::GetBinaryPath() const
{
CString path;
DWORD bytes_required;
::QueryServiceConfig(m_sc_service, NULL, 0, &bytes_required);
if (GetLastError() == ERROR_INSUFFICIENT_BUFFER)
{
void *buffer = operator new(bytes_required);
LPQUERY_SERVICE_CONFIG config = reinterpret_cast<LPQUERY_SERVICE_CONFIG>(buffer);
if (::QueryServiceConfig(m_sc_service, config, bytes_required, &bytes_required))
{
path = config->lpBinaryPathName;
}
delete buffer;
}
return path;
}
DWORD Service::GetStartup() const
{
DWORD result = 0xffffffff;
const size_t BUFFER_SIZE = 8192;
void *buffer = operator new(BUFFER_SIZE);
LPQUERY_SERVICE_CONFIG config = reinterpret_cast<LPQUERY_SERVICE_CONFIG>(buffer);
DWORD bytes_required;
if (::QueryServiceConfig(m_sc_service, config, BUFFER_SIZE, &bytes_required))
result = config->dwStartType;
delete buffer;
return result;
}
bool Service::ConfigureStartup(DWORD startup) {
if(startup != GetStartup()) { // don't boost privs if we don't need to
if(startup == SERVICE_AUTO_START) {
return ExecHelper(_T("auto"));
} else {
return ExecHelper(_T("manual"));
}
}
return true;
}
void ServiceStatusMonitor::Poll(Service *service)
{
Service::Status new_status;
if (service->GetStatus(&new_status))
{
if (!m_service_status.IsValid() || (m_service_status != new_status))
{
FireServiceStatus(m_service_status, new_status);
m_service_status = new_status;
}
}
}

View File

@ -1,174 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef SERVICECONTROL_H
#define SERVICECONTROL_H
class Service
{
SC_HANDLE m_sc_manager;
SC_HANDLE m_sc_service;
bool m_can_control;
CString m_name;
public:
class Status : public SERVICE_STATUS
{
bool WaitPending();
public:
Status()
{
SERVICE_STATUS *clearable_this = this;
ZeroMemory(clearable_this, sizeof(SERVICE_STATUS));
}
bool operator==(const Status &r) const
{
const SERVICE_STATUS *lhs = this;
const SERVICE_STATUS *rhs = &r;
return memcmp(lhs, rhs, sizeof(SERVICE_STATUS)) == 0;
}
bool operator!=(const Status &r) const
{
const SERVICE_STATUS *lhs = this;
const SERVICE_STATUS *rhs = &r;
return memcmp(lhs, rhs, sizeof(SERVICE_STATUS)) != 0;
}
void AssertValid() const
{
// If we've been written then this shouldn't be zero.
ATLASSERT(dwCurrentState != 0);
}
bool IsValid() const
{
return dwCurrentState != 0;
}
bool IsRunning() const
{
AssertValid();
return dwCurrentState == SERVICE_RUNNING;
}
bool IsStopped() const
{
AssertValid();
return dwCurrentState == SERVICE_STOPPED;
}
bool IsPaused() const
{
AssertValid();
return dwCurrentState == SERVICE_PAUSED;
}
bool IsPending() const
{
AssertValid();
switch (dwCurrentState)
{
case SERVICE_CONTINUE_PENDING:
case SERVICE_PAUSE_PENDING:
case SERVICE_START_PENDING:
case SERVICE_STOP_PENDING:
return true;
default:
return false;
}
}
};
Service() : m_sc_manager(NULL), m_sc_service(NULL), m_can_control(false) {}
~Service() { Close(); }
bool IsOpen() const
{
return m_sc_service != NULL;
}
bool Open(const TCHAR *name);
void Close();
bool GetStatus(Status *status) const;
bool Start();
bool StartAndWait();
bool Stop();
bool StopAndWait();
bool WaitPending(Status *status, DWORD existing_state);
bool PollPending(Status *status, DWORD existing_state);
bool CanControl() const
{
// For the time being - need to deal with running as a user that can't control.
return IsOpen() && m_can_control;
}
CString GetBinaryPath() const;
/// Pass SERVICE_AUTO_START, SERVICE_BOOT_START, SERVICE_DEMAND_START,
/// SERVICE_DISABLED or SERVICE_SYSTEM_START.
bool ConfigureStartup(DWORD dwStartup);
DWORD GetStartup() const;
private:
bool ExecHelper(const TCHAR *szAction);
};
class ServiceStatusObserver
{
public:
virtual void OnServiceStatus(Service::Status old_status, Service::Status new_status) = 0;
};
class ServiceStatusMonitor
{
Service::Status m_service_status;
std::vector<ServiceStatusObserver *> m_service_observers;
void FireServiceStatus(Service::Status old_status, Service::Status new_status)
{
std::vector<ServiceStatusObserver *>::iterator i = m_service_observers.begin();
while (i != m_service_observers.end())
{
(*i)->OnServiceStatus(old_status, new_status);
++i;
}
}
public:
void Poll(Service *service);
void Subscribe(ServiceStatusObserver *obs)
{
m_service_observers.push_back(obs);
}
void Unsubscribe(ServiceStatusObserver *obs)
{
std::vector<ServiceStatusObserver *>::iterator i = std::find(m_service_observers.begin(), m_service_observers.end(), obs);
ATLASSERT(i != m_service_observers.end());
if (i != m_service_observers.end())
{
m_service_observers.erase(i);
}
}
};
#endif // SERVICECONTROL_H

View File

@ -1,111 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#include "VersionInfo.h"
bool VersionInfo::Open(const TCHAR *filename)
{
Close();
DWORD useless;
m_size = GetFileVersionInfoSize(filename, &useless);
if (m_size)
{
m_buffer = operator new(m_size);
::ZeroMemory(m_buffer, m_size);
if (GetFileVersionInfo(filename, 0, static_cast<DWORD>(m_size), m_buffer))
{
return IdentifySubBlock();
}
else
Close();
}
return false;
}
bool VersionInfo::IdentifySubBlock()
{
m_subblock.Empty();
WORD required_langid = LANGIDFROMLCID(GetUserDefaultLCID());
UINT cbTranslate;
struct LANGANDCODEPAGE
{
WORD wLanguage;
WORD wCodePage;
} *lpTranslate;
if (VerQueryValue(m_buffer, _T("\\VarFileInfo\\Translation"),
reinterpret_cast<LPVOID*>(&lpTranslate),
&cbTranslate))
{
// Try and find the user's language, but if we can't then just use the
// first one in the file.
int lang_index = -1;
for(unsigned i=0; i < (cbTranslate/sizeof(struct LANGANDCODEPAGE)); i++ )
{
// If we have an exact match then great.
if (lpTranslate[i].wLanguage == required_langid)
{
lang_index = i;
break;
}
// Otherwise settle for a primary language match and keep looking
else if ((PRIMARYLANGID(lpTranslate[i].wLanguage) == PRIMARYLANGID(required_langid)) && (lang_index < 0))
{
lang_index = i;
}
}
if (lang_index < 0)
{
ATLTRACE("Failed to find a matching language. Just using the first one.\n");
lang_index = 0;
}
m_subblock.Format(_T("\\StringFileInfo\\%04x%04x\\"), lpTranslate[lang_index].wLanguage, lpTranslate[lang_index].wCodePage);
return true;
}
return false;
}
void VersionInfo::Close()
{
if (m_buffer)
{
delete m_buffer;
m_buffer = NULL;
}
}
CString VersionInfo::GetString(const TCHAR *name) const
{
CString path = m_subblock + name;
LPVOID buffer;
UINT cb;
if (VerQueryValue(m_buffer, const_cast<LPTSTR>(static_cast<LPCTSTR>(path)), &buffer, &cb))
{
return CString(static_cast<LPCTSTR>(buffer), cb);
}
return CString();
}
//CString VersionInfo::GetStringFileVersion()
//{
// VerQueryValue(m_buffer,
//}

View File

@ -1,46 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef VERSIONINFO_H
#define VERSIONINFO_H
class VersionInfo
{
size_t m_size;
void *m_buffer;
CString m_subblock;
bool IdentifySubBlock();
CString GetString(const TCHAR *name) const;
public:
VersionInfo() : m_size(0), m_buffer(NULL) {}
bool Open(const TCHAR *filename);
void Close();
CString GetFileDescription() const
{
return GetString(_T("FileDescription"));
}
CString GetFileVersion() const
{
return GetString(_T("FileVersion"));
}
};
#endif // VERSIONINFO_H

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

View File

@ -1,70 +0,0 @@
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by FireflyShell.rc
//
#define IDR_MAINFRAME 128
#define IDS_SERVER_RUNNING 129
#define IDS_SERVER_STOPPED 130
#define IDS_SERVERSTARTFAIL 131
#define IDS_SERVERSTOPFAIL 132
#define IDS_SERVER_PENDING 133
#define IDS_SERVER_START 134
#define IDS_SERVER_STOP 135
#define IDS_SCAN_START 136
#define IDS_SCAN_STOP 137
#define IDS_NOT_ADMIN 138
#define IDS_QUERYSERVERRESTART 139
#define IDS_VERSIONINFO_DESCRIPTION 140
#define IDS_VERSIONINFO_VERSION 141
#define IDS_VERSIONINFO_PATH 142
#define IDS_FAILED_CONFIGURE_SERVICE 143
#define IDS_FAILED_CONFIGURE_STARTUP 144
#define IDS_LOG_NOLOG 145
#define IDS_LOG_OPENFAILED 146
#define IDD_PAGE_BASIC 201
#define IDD_PAGE_ADVANCED 202
#define IDD_PAGE_LOG 203
#define IDD_PAGE_ABOUT 204
#define IDI_SHELL_STOPPED 207
#define IDB_LOGO 208
#define IDC_SERVERNAME 1000
#define IDC_PATH 1001
#define IDC_BROWSE 1002
#define IDI_SHELL_RUNNING 1003
#define IDM_CONTEXT 1003
#define IDC_LOG 1003
#define ID_CONFIGURE 1004
#define IDC_PROTECT 1004
#define IDC_PASSWORD 1005
#define IDC_PASSWORD_PROMPT 1006
#define ID_EXIT 1007
#define IDC_PORTSPIN 1007
#define IDC_STARTSERVICE 1008
#define IDC_SERVERPORT 1009
#define IDC_STOPSERVICE 1010
#define IDC_SERVERSTATE 1011
#define IDC_AUTOSTART 1012
#define IDC_WEBADMIN 1013
#define IDC_WEBSITE 1014
#define IDC_AUTOSTART2 1014
#define IDC_AUTOSTART_ICON 1014
#define IDC_VERSIONLIST 1015
#define IDC_COPY 1016
#define IDC_REFRESH 1018
#define IDC_LOGO 1019
#define IDC_FIREFLYLINK 1020
#define IDC_FIREFLYLINK2 1021
#define IDC_ROKULINK 1021
#define IDI_SHIELD 1022
#define ID_SHELLNOTIFY 4242
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 209
#define _APS_NEXT_COMMAND_VALUE 32773
#define _APS_NEXT_CONTROL_VALUE 1023
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif

View File

@ -1,49 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#ifndef SINGLETON_H
#define SINGLETON_H
template <class T>
class Singleton
{
static T *sm_instance;
public:
Singleton()
{
T *instance = static_cast<T *>(this);
ATLASSERT(sm_instance == NULL);
sm_instance = instance;
}
virtual ~Singleton()
{
ATLASSERT(sm_instance != NULL);
sm_instance = NULL;
}
static T *GetInstance()
{
ATLASSERT(sm_instance != NULL);
return sm_instance;
}
};
template <class T>
T *Singleton<T>::sm_instance;
#endif // SINGLETON_H

View File

@ -1,21 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#include "stdafx.h"
#if (_ATL_VER < 0x0700)
#include <atlimpl.cpp>
#endif //(_ATL_VER < 0x0700)

View File

@ -1,80 +0,0 @@
/*
*(C) 2006 Roku LLC
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License Version 2 as published
* by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the GNU General
* Public License for more details.
*
* Please read README.txt in the same directory as this source file for
* further license information.
*/
#pragma once
// Change these values to use different versions
#define WINVER 0x0400
#define _WIN32_WINNT 0x0600
#define _WIN32_IE 0x0500
#define _RICHEDIT_VER 0x0100
#define _UNICODE
#define UNICODE
// Visual C++ 2005's new secure string operations and deprecation
#define USE_SECURE 0
#if defined(_MSC_VER)
#if _MSC_VER >= 1400
#undef USE_SECURE
#define USE_SECURE 1
#define _CRT_SECURE_NO_DEPRECATE
#endif // _MSC_VER >= 1400
#endif // defined(_MSC_VER)
#include <atlbase.h>
#include <atlapp.h>
extern CAppModule _Module;
#include <atlwin.h>
#include <atlframe.h>
#include <atlctrls.h>
#include <atldlgs.h>
#include <atlmisc.h>
#include <atlddx.h>
#include <atlcrack.h>
#include <atlctrlx.h>
#include <vector>
#include <algorithm>
// WtsApi32.h is only in the latest platform SDK. Don't rely
// on everyone having it.
#if !defined(NOTIFY_FOR_THIS_SESSION)
#define NOTIFY_FOR_THIS_SESSION 0
#endif
#if _MSC_VER >= 1400
#if defined _M_IX86
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='x86' publicKeyToken='6595b64144ccf1df' language='*'\"")
#elif defined _M_IA64
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='ia64' publicKeyToken='6595b64144ccf1df' language='*'\"")
#elif defined _M_X64
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='amd64' publicKeyToken='6595b64144ccf1df' language='*'\"")
#else
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'\"")
#endif
#endif
inline void SafeStringCopy(TCHAR *dest, const TCHAR *source, size_t len)
{
#if USE_SECURE
_tcsncpy_s(dest, len, source, len);
#else
_tcsncpy(dest, source, len);
dest[len - 1] = 0;
#endif
}

View File

@ -1,13 +0,0 @@
/* Version number of package */
#define VERSION_MAJOR 1
#define VERSION_MID 0
#define VERSION_MINOR 0
#define VERSION_BUILD $WCREV$
#define VERSION_LOCAL "$WCMODS? (LOCAL):$"
#define BUILD_DATE "$WCNOW$"
#define REPO_DATE "$WCDATE$"
#define VERSION_STRIZE2(x) #x
#define VERSION_STRIZE(x) VERSION_STRIZE2(x)
#define VERSION_STRING VERSION_STRIZE(VERSION_MAJOR) "." VERSION_STRIZE(VERSION_MID) " svn-" VERSION_STRIZE(VERSION_BUILD) VERSION_LOCAL

View File

@ -1,44 +0,0 @@
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
#include "version.h"
#include "winver.h"
#ifndef APSTUDIO_INVOKED
VS_VERSION_INFO VERSIONINFO
FILEVERSION VERSION_MAJOR, VERSION_MID, VERSION_MINOR, VERSION_BUILD
PRODUCTVERSION VERSION_MAJOR, VERSION_MID, VERSION_MINOR, VERSION_BUILD
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS VS_FF_DEBUG
#else
FILEFLAGS 0x0L
#endif
FILEOS VOS_NT_WINDOWS32
FILETYPE VFT_APP
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "CompanyName", "Roku LLC"
VALUE "FileDescription", "FireflyShell"
VALUE "FileVersion", VERSION_STRING
VALUE "InternalName", "FireflyShell"
VALUE "LegalCopyright", "Copyright 2006 Roku LLC"
VALUE "OriginalFilename", "FireflyShell.exe"
VALUE "ProductName", "Firefly Media Server"
VALUE "ProductVersion", VERSION_STRING
VALUE "Comments", "Build date: " BUILD_DATE "\r\nRepository date: " REPO_DATE "\r\n"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x409, 1200
END
END
#endif //APSTUDIO_INVOKED

View File

@ -1,160 +0,0 @@
/* config.h. Generated by configure. */
/* config.h.in. Generated from configure.in by autoheader. */
/* Define to 1 if you have the `atoll' function. */
#define HAVE_ATOLL 1
/* Define to 1 if you have the <fcntl.h> header file. */
#define HAVE_FCNTL_H 1
/* Define to 1 if you have the <FLAC/metadata.h> header file. */
/* #undef HAVE_FLAC_METADATA_H */
/* Define to 1 if you have the <getopt.h> header file. */
#define HAVE_GETOPT_H 1
/* Define to 1 if you have the <id3tag.h> header file. */
#define HAVE_ID3TAG_H 1
/* Define to 1 if you have the <inttypes.h> header file. */
#define HAVE_INTTYPES_H 1
/* Define to 1 if you have the `FLAC' library (-lFLAC). */
/* #undef HAVE_LIBFLAC */
/* Define to 1 if you have the `id3tag' library (-lid3tag). */
#define HAVE_LIBID3TAG 1
/* Define to 1 if you have the `ogg' library (-logg). */
/* #undef HAVE_LIBOGG */
/* Define to 1 if you have the `sqlite' library (-lsqlite). */
#define HAVE_LIBSQLITE 1
/* Define to 1 if you have the `sqlite3' library (-lsqlite3). */
#define HAVE_LIBSQLITE3 1
/* Define to 1 if you have the `vorbis' library (-lvorbis). */
/* #undef HAVE_LIBVORBIS */
/* Define to 1 if you have the `vorbisfile' library (-lvorbisfile). */
/* #undef HAVE_LIBVORBISFILE */
/* Define to 1 if you have the <memory.h> header file. */
#define HAVE_MEMORY_H 1
/* Define to 1 if you have the <ogg/ogg.h> header file. */
/* #undef HAVE_OGG_OGG_H */
/* Define to 1 if you have the `select' function. */
#define HAVE_SELECT 1
/* Define to 1 if you have the `socket' function. */
#define HAVE_SOCKET 1
/* Define to 1 if you have the <sqlite3.h> header file. */
#define HAVE_SQLITE3_H 1
/* Define to 1 if you have the <sqlite.h> header file. */
#define HAVE_SQLITE_H 1
/* Define to 1 if you have the <stdint.h> header file. */
/* #define HAVE_STDINT_H 1 */
/* Define to 1 if you have the <stdlib.h> header file. */
#define HAVE_STDLIB_H 1
/* Define to 1 if you have the `strcasestr' function. */
/* #define HAVE_STRCASESTR 1 */
/* Define to 1 if you have the `strdup' function. */
#define HAVE_STRDUP 1
/* Define to 1 if you have the `strerror' function. */
#define HAVE_STRERROR 1
/* Define to 1 if you have the <strings.h> header file. */
/* #define HAVE_STRINGS_H 1 */
/* Define to 1 if you have the <string.h> header file. */
#define HAVE_STRING_H 1
/* Define to 1 if you have the `strsep' function. */
#define HAVE_STRSEP 1
/* Define to 1 if you have the <syslog.h> header file. */
#define HAVE_SYSLOG_H 1
/* Define to 1 if you have the <sys/filio.h> header file. */
#define HAVE_SYS_FILIO_H 1
/* Define to 1 if you have the <sys/ioctl.h> header file. */
#define HAVE_SYS_IOCTL_H 1
/* Define to 1 if you have the <sys/stat.h> header file. */
#define HAVE_SYS_STAT_H 1
/* Define to 1 if you have the <sys/time.h> header file. */
/* #define HAVE_SYS_TIME_H 1 */
/* Define to 1 if you have the <sys/types.h> header file. */
#define HAVE_SYS_TYPES_H 1
/* Define to 1 if you have <sys/wait.h> that is POSIX.1 compatible. */
/* #define HAVE_SYS_WAIT_H 1 */
/* Define to 1 if you have the <taglib/tag_c.h> header file. */
/* #undef HAVE_TAGLIB_TAG_C_H */
/* Define to 1 if you have the <termio.h> header file. */
/* #undef HAVE_TERMIO_H */
/* Define to 1 if you have the <unistd.h> header file. */
/* #define HAVE_UNISTD_H 1 */
/* Define to 1 if you have the <vorbis/codec.h> header file. */
/* #undef HAVE_VORBIS_CODEC_H */
/* Name of package */
#define PACKAGE "Firefly Media Server"
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT ""
/* Define to the full name of this package. */
#define PACKAGE_NAME ""
/* Define to the full name and version of this package. */
#define PACKAGE_STRING ""
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME ""
/* Define to the version of this package. */
#define PACKAGE_VERSION ""
/* Define as the return type of signal handlers (`int' or `void'). */
#define RETSIGTYPE void
/* Define to 1 if the `setpgrp' function takes no argument. */
/* #undef SETPGRP_VOID */
/* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1
/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
#define TIME_WITH_SYS_TIME 1
/* */
#define HAVE_SQL
#define HAVE_ICONV
#define ICONV_CONST const
/* Version number of package */
#define VERSION "svn-$WCREV$"
#define BUILD_DATE "$WCNOW$"
#define REPO_DATE "$WCDATE$"
#include "win32.h"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

View File

@ -1,28 +0,0 @@
;#ifndef __MESSAGES_H__
;#define __MESSAGES_H__
;
;
; // Eventlog messages? What's this rubbish? I'll just make a
; // single message so I can reduce the eventlog api to syslog(3). <sigh>
; // Perhaps this isn't as win32ish as it could be. :)
;
LanguageNames =
(
English = 0x0409:Messages_ENU
)
;////////////////////////////////////////
;// Events
;//
MessageId = +1
SymbolicName = EVENT_MSG
Language = English
%1
.
;
;#endif //__MESSAGES_H__
;

View File

@ -1,17 +0,0 @@
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by mt-daapd.rc
//
#define IDI_APPICON 5
#define IDI_ICON1 201
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 202
#define _APS_NEXT_COMMAND_VALUE 32768
#define _APS_NEXT_CONTROL_VALUE 201
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif

View File

@ -1,110 +0,0 @@
// Microsoft Visual C++ generated resource script.
//
#include "mt-daapd-res.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include <windows.h>
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"mt-daapd-res.h\0"
END
2 TEXTINCLUDE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE
BEGIN
"#include ""res/Messages.rc""\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,0,0,$WCREV$
PRODUCTVERSION 1,0,0,$WCREV$
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "Comments", "http://www.fireflymediaserver.org"
VALUE "CompanyName", "Ron Pedde"
VALUE "FileDescription", "Firefly Service"
VALUE "FileVersion", "1.0 svn-$WCREV$"
VALUE "InternalName", "firefly"
VALUE "LegalCopyright", "Copyright (C) 2006 Ron Pedde"
VALUE "OriginalFilename", "firefly.exe"
VALUE "ProductName", "Firefly Media Server"
VALUE "ProductVersion", "1.0 svn-$WCREV$"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x409, 1200
END
END
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDI_APPICON ICON "ff.ico"
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
#include "res/Messages.rc"
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@ -1,97 +0,0 @@
Microsoft Visual Studio Solution File, Format Version 9.00
# Visual Studio 2005
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mt-daapd", "mt-daapd.vcproj", "{CB40C666-11D7-456B-B774-BCA42F675BB5}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "rsp", "rsp.vcproj", "{68CCEA19-503F-4894-8AE3-B1673FDEA920}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "w32-event", "w32-event.vcproj", "{E60F90F1-A1E5-49D8-A565-B990CA4BA860}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ssc-ffmpeg", "ssc-ffmpeg.vcproj", "{DA27D6F4-7E9F-40CA-AC5C-480DC81A1C56}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FireflyShell", "FireflyShell\FireflyShell.vcproj", "{ED38F171-854B-4EA3-B3A0-7681648969FC}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ssc-wma", "ssc-wma\ssc-wma.vcproj", "{C1EF5133-DFB3-4FEC-B999-3655DBB14785}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "out-daap", "out-daap\out-daap.vcproj", "{C1EF5133-DFB3-4FEC-B999-3655DBB14786}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FireflyShellFRA", "FireflyShell\FireflyShellFRA.vcproj", "{819028A4-ED43-4A51-9E32-DC8559ADEBB6}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FireflyShellNLD", "FireflyShell\FireflyShellNLD.vcproj", "{5D6F19F6-6A71-4960-BFB3-BF545D02ACBD}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FireflyShellDEU", "FireflyShell\FireflyShellDEU.vcproj", "{9B035724-EAD7-48C5-BBAF-91FFAA3CA55F}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FireflyShellJPN", "FireflyShell\FireflyShellJPN.vcproj", "{59618041-38FA-4D80-B00B-113417259E6D}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FireflyShellSWE", "FireflyShell\FireflyShellSWE.vcproj", "{D8109A27-5CB3-4888-B62A-F83BB3B1D41F}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FireflyShellITA", "FireflyShell\FireflyShellITA.vcproj", "{E8F129E2-CABC-4FCD-9A9E-CDE338F4B1D0}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "svcctrl", "svcctrl\svcctrl.vcproj", "{C49A74DC-C9A3-4562-9BA1-F903AADE87C2}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
Release|Win32 = Release|Win32
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{CB40C666-11D7-456B-B774-BCA42F675BB5}.Debug|Win32.ActiveCfg = Debug|Win32
{CB40C666-11D7-456B-B774-BCA42F675BB5}.Debug|Win32.Build.0 = Debug|Win32
{CB40C666-11D7-456B-B774-BCA42F675BB5}.Release|Win32.ActiveCfg = Release|Win32
{CB40C666-11D7-456B-B774-BCA42F675BB5}.Release|Win32.Build.0 = Release|Win32
{68CCEA19-503F-4894-8AE3-B1673FDEA920}.Debug|Win32.ActiveCfg = Debug|Win32
{68CCEA19-503F-4894-8AE3-B1673FDEA920}.Debug|Win32.Build.0 = Debug|Win32
{68CCEA19-503F-4894-8AE3-B1673FDEA920}.Release|Win32.ActiveCfg = Release|Win32
{68CCEA19-503F-4894-8AE3-B1673FDEA920}.Release|Win32.Build.0 = Release|Win32
{E60F90F1-A1E5-49D8-A565-B990CA4BA860}.Debug|Win32.ActiveCfg = Debug|Win32
{E60F90F1-A1E5-49D8-A565-B990CA4BA860}.Debug|Win32.Build.0 = Debug|Win32
{E60F90F1-A1E5-49D8-A565-B990CA4BA860}.Release|Win32.ActiveCfg = Release|Win32
{E60F90F1-A1E5-49D8-A565-B990CA4BA860}.Release|Win32.Build.0 = Release|Win32
{DA27D6F4-7E9F-40CA-AC5C-480DC81A1C56}.Debug|Win32.ActiveCfg = Debug|Win32
{DA27D6F4-7E9F-40CA-AC5C-480DC81A1C56}.Debug|Win32.Build.0 = Debug|Win32
{DA27D6F4-7E9F-40CA-AC5C-480DC81A1C56}.Release|Win32.ActiveCfg = Release|Win32
{DA27D6F4-7E9F-40CA-AC5C-480DC81A1C56}.Release|Win32.Build.0 = Release|Win32
{ED38F171-854B-4EA3-B3A0-7681648969FC}.Debug|Win32.ActiveCfg = Debug|Win32
{ED38F171-854B-4EA3-B3A0-7681648969FC}.Debug|Win32.Build.0 = Debug|Win32
{ED38F171-854B-4EA3-B3A0-7681648969FC}.Release|Win32.ActiveCfg = Release|Win32
{ED38F171-854B-4EA3-B3A0-7681648969FC}.Release|Win32.Build.0 = Release|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14785}.Debug|Win32.ActiveCfg = Debug|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14785}.Debug|Win32.Build.0 = Debug|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14785}.Release|Win32.ActiveCfg = Release|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14785}.Release|Win32.Build.0 = Release|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14786}.Debug|Win32.ActiveCfg = Debug|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14786}.Debug|Win32.Build.0 = Debug|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14786}.Release|Win32.ActiveCfg = Release|Win32
{C1EF5133-DFB3-4FEC-B999-3655DBB14786}.Release|Win32.Build.0 = Release|Win32
{819028A4-ED43-4A51-9E32-DC8559ADEBB6}.Debug|Win32.ActiveCfg = Debug|Win32
{819028A4-ED43-4A51-9E32-DC8559ADEBB6}.Debug|Win32.Build.0 = Debug|Win32
{819028A4-ED43-4A51-9E32-DC8559ADEBB6}.Release|Win32.ActiveCfg = Release|Win32
{819028A4-ED43-4A51-9E32-DC8559ADEBB6}.Release|Win32.Build.0 = Release|Win32
{5D6F19F6-6A71-4960-BFB3-BF545D02ACBD}.Debug|Win32.ActiveCfg = Debug|Win32
{5D6F19F6-6A71-4960-BFB3-BF545D02ACBD}.Debug|Win32.Build.0 = Debug|Win32
{5D6F19F6-6A71-4960-BFB3-BF545D02ACBD}.Release|Win32.ActiveCfg = Release|Win32
{5D6F19F6-6A71-4960-BFB3-BF545D02ACBD}.Release|Win32.Build.0 = Release|Win32
{9B035724-EAD7-48C5-BBAF-91FFAA3CA55F}.Debug|Win32.ActiveCfg = Debug|Win32
{9B035724-EAD7-48C5-BBAF-91FFAA3CA55F}.Debug|Win32.Build.0 = Debug|Win32
{9B035724-EAD7-48C5-BBAF-91FFAA3CA55F}.Release|Win32.ActiveCfg = Release|Win32
{9B035724-EAD7-48C5-BBAF-91FFAA3CA55F}.Release|Win32.Build.0 = Release|Win32
{59618041-38FA-4D80-B00B-113417259E6D}.Debug|Win32.ActiveCfg = Debug|Win32
{59618041-38FA-4D80-B00B-113417259E6D}.Debug|Win32.Build.0 = Debug|Win32
{59618041-38FA-4D80-B00B-113417259E6D}.Release|Win32.ActiveCfg = Release|Win32
{59618041-38FA-4D80-B00B-113417259E6D}.Release|Win32.Build.0 = Release|Win32
{D8109A27-5CB3-4888-B62A-F83BB3B1D41F}.Debug|Win32.ActiveCfg = Debug|Win32
{D8109A27-5CB3-4888-B62A-F83BB3B1D41F}.Debug|Win32.Build.0 = Debug|Win32
{D8109A27-5CB3-4888-B62A-F83BB3B1D41F}.Release|Win32.ActiveCfg = Release|Win32
{D8109A27-5CB3-4888-B62A-F83BB3B1D41F}.Release|Win32.Build.0 = Release|Win32
{E8F129E2-CABC-4FCD-9A9E-CDE338F4B1D0}.Debug|Win32.ActiveCfg = Debug|Win32
{E8F129E2-CABC-4FCD-9A9E-CDE338F4B1D0}.Debug|Win32.Build.0 = Debug|Win32
{E8F129E2-CABC-4FCD-9A9E-CDE338F4B1D0}.Release|Win32.ActiveCfg = Release|Win32
{E8F129E2-CABC-4FCD-9A9E-CDE338F4B1D0}.Release|Win32.Build.0 = Release|Win32
{C49A74DC-C9A3-4562-9BA1-F903AADE87C2}.Debug|Win32.ActiveCfg = Debug|Win32
{C49A74DC-C9A3-4562-9BA1-F903AADE87C2}.Debug|Win32.Build.0 = Debug|Win32
{C49A74DC-C9A3-4562-9BA1-F903AADE87C2}.Release|Win32.ActiveCfg = Release|Win32
{C49A74DC-C9A3-4562-9BA1-F903AADE87C2}.Release|Win32.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

View File

@ -1,495 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="firefly"
ProjectGUID="{CB40C666-11D7-456B-B774-BCA42F675BB5}"
RootNamespace="mt-daapd"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="Debug"
IntermediateDirectory="Debug"
ConfigurationType="1"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="$(InputDir),..\src,.,.."
PreprocessorDefinitions="HAVE_CONFIG_H;ZLIB_DLL;_WINDOWS;WIN32;FLAC;OGGVORBIS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
AdditionalIncludeDirectories="C:\working\projects\win32\include"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="zdll.lib libid3tag.lib gnu_regex.lib pthreadVC2.lib ws2_32.lib sqlite3.lib sqlite.lib dnssd.lib libFLAC.lib ogg_static.lib vorbis_static.lib vorbisfile_static.lib iconv.lib"
OutputFile="$(OutDir)/firefly.exe"
LinkIncremental="2"
AdditionalLibraryDirectories=""
IgnoreDefaultLibraryNames="libc"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/mt-daapd.pdb"
SubSystem="1"
ImportLibrary="firefly.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="1"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories="$(InputDir),..\src,.,.."
PreprocessorDefinitions="HAVE_CONFIG_H;ZLIB_DLL;_WINDOWS;WIN32;FLAC;OGGVORBIS"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
AdditionalIncludeDirectories="C:\working\projects\win32\include"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="zdll.lib libid3tag.lib gnu_regex.lib pthreadVC2.lib ws2_32.lib sqlite3.lib sqlite.lib dnssd.lib libFLAC.lib ogg_static.lib vorbis_static.lib vorbisfile_static.lib iconv.lib"
OutputFile="$(OutDir)/firefly.exe"
LinkIncremental="1"
AdditionalLibraryDirectories=""
IgnoreDefaultLibraryNames="libc"
GenerateDebugInformation="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ImportLibrary="firefly.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File
RelativePath="..\src\bsd-snprintf.c"
>
</File>
<File
RelativePath="..\src\compat.c"
>
</File>
<File
RelativePath="..\src\conf.c"
>
</File>
<File
RelativePath="..\src\configfile.c"
>
</File>
<File
RelativePath="..\src\db-generic.c"
>
</File>
<File
RelativePath="..\src\db-sql-sqlite2.c"
>
</File>
<File
RelativePath="..\src\db-sql-sqlite3.c"
>
</File>
<File
RelativePath="..\src\db-sql-updates.c"
>
</File>
<File
RelativePath="..\src\db-sql.c"
>
</File>
<File
RelativePath="..\src\err.c"
>
</File>
<File
RelativePath="..\src\ff-plugins.c"
>
</File>
<File
RelativePath="..\src\getopt.c"
>
</File>
<File
RelativePath="..\src\io.c"
>
</File>
<File
RelativePath="..\src\ll.c"
>
</File>
<File
RelativePath="..\src\main.c"
>
</File>
<File
RelativePath="..\src\mp3-scanner.c"
>
</File>
<File
RelativePath="..\src\os-win32.c"
>
</File>
<File
RelativePath="..\src\plugin.c"
>
</File>
<File
RelativePath="..\src\redblack.c"
>
</File>
<File
RelativePath="..\src\rend-win32.c"
>
</File>
<File
RelativePath="..\src\rxml.c"
>
</File>
<File
RelativePath="..\src\scan-aac.c"
>
</File>
<File
RelativePath="..\src\scan-aif.c"
>
</File>
<File
RelativePath="..\src\scan-flac.c"
>
</File>
<File
RelativePath="..\src\scan-mp3.c"
>
</File>
<File
RelativePath="..\src\scan-ogg.c"
>
</File>
<File
RelativePath="..\src\scan-url.c"
>
</File>
<File
RelativePath="..\src\scan-wav.c"
>
</File>
<File
RelativePath="..\src\scan-wma.c"
>
</File>
<File
RelativePath="..\src\scan-xml.c"
>
</File>
<File
RelativePath="..\src\smart-parser.c"
>
</File>
<File
RelativePath="..\src\util.c"
>
</File>
<File
RelativePath="..\src\w32-eventlog.c"
>
</File>
<File
RelativePath="..\src\w32-service.c"
>
</File>
<File
RelativePath="..\src\webserver.c"
>
</File>
<File
RelativePath="..\src\xml-rpc.c"
>
</File>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
<File
RelativePath="..\src\conf.h"
>
</File>
<File
RelativePath=".\config.h"
>
</File>
<File
RelativePath="..\src\configfile.h"
>
</File>
<File
RelativePath="..\src\daapd.h"
>
</File>
<File
RelativePath="..\src\dispatch.h"
>
</File>
<File
RelativePath="..\src\err.h"
>
</File>
<File
RelativePath="..\src\ff-plugins.h"
>
</File>
<File
RelativePath="..\src\io-errors.h"
>
</File>
<File
RelativePath="..\src\io-plugin.h"
>
</File>
<File
RelativePath="..\src\io.h"
>
</File>
<File
RelativePath="..\src\ll.h"
>
</File>
<File
RelativePath=".\mt-daapd-res.h"
>
</File>
<File
RelativePath="..\src\os-win32.h"
>
</File>
<File
RelativePath="..\src\os.h"
>
</File>
<File
RelativePath="..\src\plugin.h"
>
</File>
<File
RelativePath="..\src\rend.h"
>
</File>
<File
RelativePath="..\src\strptime.h"
>
</File>
<File
RelativePath="..\src\strtok_r.h"
>
</File>
<File
RelativePath="..\src\uici.h"
>
</File>
<File
RelativePath="..\src\util.h"
>
</File>
<File
RelativePath="..\src\w32-eventlog.h"
>
</File>
<File
RelativePath="..\src\w32-service.h"
>
</File>
<File
RelativePath="..\src\webserver.h"
>
</File>
<File
RelativePath="..\src\win32.h"
>
</File>
</Filter>
<Filter
Name="Resource Files"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\ff.ico"
>
</File>
<File
RelativePath=".\mt-daapd.rc"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCResourceCompilerTool"
AdditionalIncludeDirectories=".;res"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCResourceCompilerTool"
AdditionalIncludeDirectories=".;res;.."
/>
</FileConfiguration>
</File>
</Filter>
<File
RelativePath=".\messages.mc"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCustomBuildTool"
CommandLine="mc.exe -A $(InputDir)$(InputName).mc -r $(InputDir)res -h $(InputDir)&#x0D;&#x0A;"
Outputs="$(InputDir)res\$(InputName).rc;$(InputDir)$(InputName).h"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCustomBuildTool"
CommandLine="mc.exe -A $(InputDir)$(InputName).mc -r $(InputDir)res -h $(InputDir)&#x0D;&#x0A;"
Outputs="$(InputDir)res\$(InputName).rc;$(InputDir)$(InputName).h"
/>
</FileConfiguration>
</File>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

Binary file not shown.

Binary file not shown.

View File

@ -1 +0,0 @@
# Firefly Log File

View File

@ -1,29 +0,0 @@
!define LANG "DUTCH"
!insertmacro LANG_STRING PRODUCT_NAME "Firefly Media Server"
; Install strings
!insertmacro LANG_STRING STRING_BONJOUR_ERROR "Bonjour voor Windows service niet gevonden. Installeer eerst Apple's Bonjour voor Windows."
!insertmacro LANG_STRING STRING_STOPPING_SERVICE "Service wordt gestopt..."
!insertmacro LANG_STRING STRING_WAITING_FOR_STOP "Wacht tot de service gestopt is ($9)"
; Strings for the application install directory panel
!insertmacro LANG_STRING STRING_DESTFOLDER "Bestemmingsfolder"
!insertmacro LANG_STRING STRING_DESTDETAIL "Setup zal ${PRODUCT_NAME} installeren in de volgende folder.$\r$\n$\r$\nOm in een andere folder te installeren, klik Doorzoek en selecteer een andere folder. Klik Volgende om door te gaan."
; Strings for the music path directory panel
!insertmacro LANG_STRING STRING_MUSICTITLE "Kies Muziek Locatie"
!insertmacro LANG_STRING STRING_MUSICHEADER "Kies folder met music om te delen."
!insertmacro LANG_STRING STRING_MUSICFOLDER "Muziek Folder"
!insertmacro LANG_STRING STRING_MUSICDETAIL "Setup zal de muziek in de folder$\r$\n$\r$\nOm in een andere folder te delen, klik Doorzoek en selecteer een andere folder. Klik Installeer om de installatie te starten."
; These are for the startmenu shortcuts
!insertmacro LANG_BOTHSTRING STRING_WEBSITE "Website"
!insertmacro LANG_BOTHSTRING STRING_UNINSTALL "Deinstalleer"
!insertmacro LANG_BOTHSTRING STRING_DEBUG_MODE "Debug Modus"
!insertmacro LANG_BOTHSTRING STRING_FF_CONFIGURATION "Firefly Configuratie"
!insertmacro LANG_BOTHSTRING STRING_ADV_CONFIG "Advanceerde Configuratie"
; Uninstall Strings
!insertmacro LANG_UNSTRING STRING_UNINSTALLED "$(^Name) was succesvol verwijderd van uw computer."
!insertmacro LANG_UNSTRING STRING_AREYOUSURE "Bent u zeker dat u $(^Name) wilt verwijderen en al zijn componenten?"

View File

@ -1,29 +0,0 @@
!define LANG "ENGLISH"
!insertmacro LANG_STRING PRODUCT_NAME "Firefly Media Server"
; Install strings
!insertmacro LANG_STRING STRING_BONJOUR_ERROR "Bonjour for Windows service not found. Please install Apple's Bonjour for Windows."
!insertmacro LANG_STRING STRING_STOPPING_SERVICE "Stopping Service..."
!insertmacro LANG_STRING STRING_WAITING_FOR_STOP "Waiting for service stop ($9)"
; Strings for the application install directory panel
!insertmacro LANG_STRING STRING_DESTFOLDER "Destination Folder"
!insertmacro LANG_STRING STRING_DESTDETAIL "Setup will install ${PRODUCT_NAME} in the following folder.$\r$\n$\r$\nTo install in a different folder, click Browse and select another folder. Click Next to continue."
; Strings for the music path directory panel
!insertmacro LANG_STRING STRING_MUSICTITLE "Choose Music Location"
!insertmacro LANG_STRING STRING_MUSICHEADER "Choose the folder containing music to share."
!insertmacro LANG_STRING STRING_MUSICFOLDER "Music Folder"
!insertmacro LANG_STRING STRING_MUSICDETAIL "Setup will share the music in the following folder.$\r$\n$\r$\nTo share a different folder, click Browse and select another folder. Click Install to start the installation."
; These are for the startmenu shortcuts
!insertmacro LANG_BOTHSTRING STRING_WEBSITE "Website"
!insertmacro LANG_BOTHSTRING STRING_UNINSTALL "Uninstall"
!insertmacro LANG_BOTHSTRING STRING_DEBUG_MODE "Debug Mode"
!insertmacro LANG_BOTHSTRING STRING_FF_CONFIGURATION "Firefly Configuration"
!insertmacro LANG_BOTHSTRING STRING_ADV_CONFIG "Advanced Configuration"
; Uninstall Strings
!insertmacro LANG_UNSTRING STRING_UNINSTALLED "$(^Name) was successfully removed from your computer."
!insertmacro LANG_UNSTRING STRING_AREYOUSURE "Are you sure you want to completely remove $(^Name) and all of its components?"

View File

@ -1,30 +0,0 @@
!define LANG "FRENCH"
!insertmacro LANG_STRING PRODUCT_NAME "Firefly Media Server"
; Install strings
!insertmacro LANG_STRING STRING_BONJOUR_ERROR "Le service Bonjour pour Windows n'a pas été trouvé. Veuillez installer le service Bonjour de Apple Pour Windows."
!insertmacro LANG_STRING STRING_STOPPING_SERVICE "Arrêter le service..."
!insertmacro LANG_STRING STRING_WAITING_FOR_STOP "Attente de l'arrêt du service ($9)"
; Strings for the application install directory panel
!insertmacro LANG_STRING STRING_DESTFOLDER "Dossier de Destination"
!insertmacro LANG_STRING STRING_DESTDETAIL "Le programme d'installation va installer ${PRODUCT_NAME} dans le dossier suivant.$\r$\n$\r$\nPour l'installer dans un dossier différent, cliquez sur Parcourir et sélectionner un autre dossier. Cliquez sur Suivant pour continuer."
; Strings for the music path directory panel
!insertmacro LANG_STRING STRING_MUSICTITLE "Choisissez l'emplacement de la Musique"
!insertmacro LANG_STRING STRING_MUSICHEADER "Choisissez le dossier contenant la musique à partager."
!insertmacro LANG_STRING STRING_MUSICFOLDER "Dossier de Musique"
!insertmacro LANG_STRING STRING_MUSICDETAIL "Le programme d'installation va partager la musique du dossier suivant.$\r$\n$\r$\nPour partager un dossier différent, cliquez sur Parcourir et sélectionnez un autre dossier. Cliquez sur Installer pour démarrer l'installation."
; These are for the startmenu shortcuts
!insertmacro LANG_BOTHSTRING STRING_WEBSITE "Site Web"
!insertmacro LANG_BOTHSTRING STRING_UNINSTALL "Désinstaller"
!insertmacro LANG_BOTHSTRING STRING_DEBUG_MODE "Mode Debug"
!insertmacro LANG_BOTHSTRING STRING_FF_CONFIGURATION "Configuration de Firefly"
!insertmacro LANG_BOTHSTRING STRING_ADV_CONFIG "Configuration Avancée"
; Uninstall Strings
!insertmacro LANG_UNSTRING STRING_UNINSTALLED "$(^Name) a été supprimé avec succès de votre ordinateur."
!insertmacro LANG_UNSTRING STRING_AREYOUSURE "Êtes-vous sûr de vouloir supprimer définitivement $(^Name) et tous ses composants?"

View File

@ -1,29 +0,0 @@
!define LANG "GERMAN"
!insertmacro LANG_STRING PRODUCT_NAME "Firefly Media Server"
; Install strings
!insertmacro LANG_STRING STRING_BONJOUR_ERROR "Der Bonjour-Dienst für Windows konnte nicht gefunden werden. Bitte installieren Sie Apples Bonjour für Windows."
!insertmacro LANG_STRING STRING_STOPPING_SERVICE "Beende Dienst..."
!insertmacro LANG_STRING STRING_WAITING_FOR_STOP "Warte, bis Dienst beendet ist ($9)"
; Strings for the application install directory panel
!insertmacro LANG_STRING STRING_DESTFOLDER "Zielpfad"
!insertmacro LANG_STRING STRING_DESTDETAIL "Setup wird ${PRODUCT_NAME} in folgenden Ordner installieren:$\r$\n$\r$\nUm in einen anderen Ordner als den ausgewählten zu installieren, klicken Sie Durchsuchen und wählen Sie einen anderen Ordner aus. Drücken Sie Weiter, um fortzufahren."
; Strings for the music path directory panel
!insertmacro LANG_STRING STRING_MUSICTITLE "Wählen Sie den Pfad zu Ihrer Musiksammlung"
!insertmacro LANG_STRING STRING_MUSICHEADER "Wählen Sie den Pfad zu den Musikdateien, die Sie freigeben möchten."
!insertmacro LANG_STRING STRING_MUSICFOLDER "Musik-Ordner"
!insertmacro LANG_STRING STRING_MUSICDETAIL "Das Setup wird die Musik in folgenden Ordnern freigeben.$\r$\n$\r$\nUm in einen anderen Ordner als den ausgewählten freizugeben, klicken Sie Durchsuchen und wählen Sie einen anderen Ordner aus. Drücken Sie Installieren um den Installationsvorgang zu beginnen."
; These are for the startmenu shortcuts
!insertmacro LANG_BOTHSTRING STRING_WEBSITE "Website"
!insertmacro LANG_BOTHSTRING STRING_UNINSTALL "Deinstallieren"
!insertmacro LANG_BOTHSTRING STRING_DEBUG_MODE "Debug Modus"
!insertmacro LANG_BOTHSTRING STRING_FF_CONFIGURATION "Firefly Konfiguration"
!insertmacro LANG_BOTHSTRING STRING_ADV_CONFIG "Erweiterte Konfiguration"
; Uninstall Strings
!insertmacro LANG_UNSTRING STRING_UNINSTALLED "$(^Name) wurde erfolgreich von Ihrem Computer entfernt."
!insertmacro LANG_UNSTRING STRING_AREYOUSURE "Sind Sie sicher, dass sie $(^Name) und damit alle Komponenten von Ihrem Computer entfernen wollen?"

View File

@ -1,30 +0,0 @@
!define LANG "ITALIAN"
!insertmacro LANG_STRING PRODUCT_NAME "Firefly Media Server"
; Install strings
!insertmacro LANG_STRING STRING_BONJOUR_ERROR "Il servizio Bonjour per Windows non è disponibile. Installare Apple Bonjour per Windows."
!insertmacro LANG_STRING STRING_STOPPING_SERVICE "Arresto del servizio in corso..."
!insertmacro LANG_STRING STRING_WAITING_FOR_STOP "Attesa per l'arresto del servizio ($9)"
; Strings for the application install directory panel
!insertmacro LANG_STRING STRING_DESTFOLDER "Cartella di destinazione"
!insertmacro LANG_STRING STRING_DESTDETAIL "Setup installerà ${PRODUCT_NAME} nella seguente cartella.$\r$\n$\r$\nPer installare in una cartella differente, fare click su Sfoglia e selezionare un'altra cartella. Fare click su Prossimo per continuare."
; Strings for the music path directory panel
!insertmacro LANG_STRING STRING_MUSICTITLE "Scelta della libreria musicale"
!insertmacro LANG_STRING STRING_MUSICHEADER "Scegliere la cartella contenente la musica da condividere."
!insertmacro LANG_STRING STRING_MUSICFOLDER "Cartella con la musica"
!insertmacro LANG_STRING STRING_MUSICDETAIL "Firefly condividerà la musica nella cartella seguente.$\r$\n$\r$\nPer condividere una cartella differente, fare click su Sfoglia e selezionare un'altra cartella. Fare click su Installa per iniziare."
; These are for the startmenu shortcuts
!insertmacro LANG_BOTHSTRING STRING_WEBSITE "Sito web"
!insertmacro LANG_BOTHSTRING STRING_UNINSTALL "Disinstalla"
!insertmacro LANG_BOTHSTRING STRING_DEBUG_MODE "Modalità Debug"
!insertmacro LANG_BOTHSTRING STRING_FF_CONFIGURATION "Configurazione di Firefly"
!insertmacro LANG_BOTHSTRING STRING_ADV_CONFIG "Configurazione Avanzata"
; Uninstall Strings
!insertmacro LANG_UNSTRING STRING_UNINSTALLED "$(^Name) è stato rimosso dal tuo computer con successo."
!insertmacro LANG_UNSTRING STRING_AREYOUSURE "Sei sicuro di volere rimuovere completamente $(^Name) con tutti i relativi componenti?"

View File

@ -1,29 +0,0 @@
!define LANG "JAPANESE"
!insertmacro LANG_STRING PRODUCT_NAME "Firefly Media Server"
; Install strings
!insertmacro LANG_STRING STRING_BONJOUR_ERROR "Windows版Bonjourサービスが見つかりません。Apple社のWindows版Bonjourをインストールしてください。"
!insertmacro LANG_STRING STRING_STOPPING_SERVICE "サービスを停止中..."
!insertmacro LANG_STRING STRING_WAITING_FOR_STOP "サービスの停止を待機中 ($9)"
; Strings for the application install directory panel
!insertmacro LANG_STRING STRING_DESTFOLDER "インストール先フォルダ"
!insertmacro LANG_STRING STRING_DESTDETAIL "セットアップは ${PRODUCT_NAME} を次のフォルダにインストールします。$\r$\n$\r$\n他のフォルダにインストールするには、「参照」ボタンをクリックして、他のフォルダを選択してください。続けるには、「次へ」ボタンをクリックしてください。"
; Strings for the music path directory panel
!insertmacro LANG_STRING STRING_MUSICTITLE "ミュージックの場所の選択"
!insertmacro LANG_STRING STRING_MUSICHEADER "共有するミュージックフォルダを選択してください。"
!insertmacro LANG_STRING STRING_MUSICFOLDER "ミュージックフォルダ"
!insertmacro LANG_STRING STRING_MUSICDETAIL "セットアップは次のフォルダにあるミュージックを共有します。$\r$\n$\r$\n他のフォルダを共有するには、「参照」ボタンをクリックして、他のフォルダを選択してください。インストールを開始するには、「インストール」ボタンをクリックしてください。"
; These are for the startmenu shortcuts
!insertmacro LANG_BOTHSTRING STRING_WEBSITE "ウェブサイト"
!insertmacro LANG_BOTHSTRING STRING_UNINSTALL "アンインストール"
!insertmacro LANG_BOTHSTRING STRING_DEBUG_MODE "デバッグモード"
!insertmacro LANG_BOTHSTRING STRING_FF_CONFIGURATION "Firefly設定"
!insertmacro LANG_BOTHSTRING STRING_ADV_CONFIG "詳細の設定"
; Uninstall Strings
!insertmacro LANG_UNSTRING STRING_UNINSTALLED "$(^Name)を正常にアンインストールすることができました。"
!insertmacro LANG_UNSTRING STRING_AREYOUSURE "本当に$(^Name)を完全にアンインストールしてもよろしいですか?"

View File

@ -1,29 +0,0 @@
!define LANG "SVENSKA"
!insertmacro LANG_STRING PRODUCT_NAME "Firefly Media Server"
; Install strings
!insertmacro LANG_STRING STRING_BONJOUR_ERROR "Bonjour för Windows tjänsten kan inte hittas. Var vänlig installera Apple's Bonjour för Windows."
!insertmacro LANG_STRING STRING_STOPPING_SERVICE "Stannar tjänsten..."
!insertmacro LANG_STRING STRING_WAITING_FOR_STOP "Väntar på att tjänsten ska stanna ($9)"
; Strings for the application install directory panel
!insertmacro LANG_STRING STRING_DESTFOLDER "Destination"
!insertmacro LANG_STRING STRING_DESTDETAIL "Installations programmet kommer installera ${PRODUCT_NAME} i följande mapp.$\r$\n$\r$\nFör att installera i en annan map, klicka Bläddra och välj en annan map. Klicka på Nästa för att fortsätta."
; Strings for the music path directory panel
!insertmacro LANG_STRING STRING_MUSICTITLE "Välj musik mapp"
!insertmacro LANG_STRING STRING_MUSICHEADER "Välj mappen som innehåller musik att dela ut."
!insertmacro LANG_STRING STRING_MUSICFOLDER "Musik Mapp"
!insertmacro LANG_STRING STRING_MUSICDETAIL "Installationen kommer dela ut musiken i följande mapp.$\r$\n$\r$\nFör att dela ut en annan mapp, klicka Bläddra och välj en annan mapp. Klicka Installera för att starta installationen."
; These are for the startmenu shortcuts
!insertmacro LANG_BOTHSTRING STRING_WEBSITE "Websida"
!insertmacro LANG_BOTHSTRING STRING_UNINSTALL "Avinstallera"
!insertmacro LANG_BOTHSTRING STRING_DEBUG_MODE "Debug Läge"
!insertmacro LANG_BOTHSTRING STRING_FF_CONFIGURATION "Firefly Konfiguration"
!insertmacro LANG_BOTHSTRING STRING_ADV_CONFIG "Avancerad Konfiguration"
; Uninstall Strings
!insertmacro LANG_UNSTRING STRING_UNINSTALLED "$(^Name) är fullständigt avinstallerad från din dator."
!insertmacro LANG_UNSTRING STRING_AREYOUSURE "Är du säker på att du vill avinstallera $(^Name) och alla dess komponenter?"

View File

@ -1,12 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges>
<requestedExecutionLevel
level="requireAdministrator"
uiAccess="true"/>
</requestedPrivileges>
</security>
</trustInfo>
</assembly>

View File

@ -1,3 +0,0 @@
# Map drive letters to unc paths so that the service
# can better locate user paths
[mapping]

View File

@ -1,298 +0,0 @@
# This is the Firefly Media Server config file.
#
# Note that any changes made to this file will require the server to be
# shut down and restarted
#
#
[general]
#
# web_root (required)
#
# Location of the admin web pages.
#
# If you installed from .RPM, .deb, or tarball with --prefix=/usr, then
# this is correct.
#
# If you installed from tarball without --prefix=/usr, then the correct
# path is probably /usr/local/share/mt-daapd/admin-root.
#
web_root=admin-root
#
# port (required)
#
# What port to listen on. It is possible to use a different
# port, but this is the default iTunes port
#
port=9999
#
# admin_pw (optional)
#
# This is the password to the administrative pages
#
# If it is blank, then no password is required from localhost,
# but nobody can connect from an outside machine (for admin
# pages).
#
# If it is set, then passwords are required for admin pages
# from both localhost and external hosts
#
# admin_pw =
#
# db_type (required)
#
# This is what kind of backend database to store the song
# info in. Valid choices are "sqlite" and "sqlite3".
#
# sqlite seems to be more stable.
db_type=sqlite3
#
# db_parms
#
# This is any extra information the db needs to connect.
# in the case of sqlite and sqlite3, this is the name
# of the directory to store the database in
#
# If you installed from RPM or .deb, this path likely already
# exists. If not, then you must create it. The directory itself
# must be writable by the "runas" user.
#
db_parms=.
#
# mp3_dir (required)
#
# Location of the mp3 files to share. Note that because the
# files are stored in the database by inode, these must be
# in the same physical filesystem.
#
mp3_dir=c:\mp3
#
# servername (required)
#
# This is both the name of the server as advertised
# via rendezvous, and the name of the database
# exported via DAAP. Also know as "What shows up in iTunes".
#
servername=Firefly Media Server
#
# runas (required)
#
# This is the user to drop privs to if running as
# root. If mt-daapd is not started as root, this
# configuration option is ignored. Notice that this
# must be specified whether the server is running
# as root or not.
#
# This is a leftover from the port from unix -- it's
# not used on windows, but still hanging around, like
# an appendix.
#
runas=nobody
#
# password (optional)
#
# This is the password required to listen to MP3 files
# i.e. the password that iTunes prompts for
#
#password=mp3
#
# extensions (optional)
#
# These are the file extensions that the daap server will
# try to index and serve. By default, it only indexes and
# serves .mp3 files. It can also server .m4a and .m4p files,
# and just about any other files, really. Unfortunately, while
# it can *attempt* to serve other files (.ogg?), iTunes won't
# play them. Perhaps this would be useful on Linux with
# Rhythmbox, once it understands daap. (hurry up!)
#
# Failing that, one can use server-side conversion to transcode
# non-standard (.ogg, .flac) music to wav on the server side.
# See the ssc_* options below.
#
extensions=.mp3,.m4a,.m4p,.wma,.flac,.ogg
#
# ssc_codectypes (optional)
#
# List of codectypes for files that the daap server should
# perform internal format conversion and present to clients
# as WAV files. The file extensions that these codectypes correspond
# to must also be present in 'extensions'
# configuration value, or files are not probed in the first
# place.
#
# Valid codectypes:
#
# mp4a - for AAC (.aac, .mp4, .m4a, .m4p)
# mpeg - for mp3
# wav - for wav
# wma - for wma
# ogg - for ogg
# flac - for flac (.flac, .fla)
# mpc for musepack (.mpc, .mpp, .mp+)
# alac for alac (.m4a)
#
#ssc_codectypes ogg,flac,alac
#
# ssc_prog (optional)
#
# Program that is used in server side format conversion.
# Program must accept following command line syntax:
# ssc_prog filename offset length ...
# Parameter filename is the real name of the file that is
# to be converted and streamed, offset is number of bytes
# that are skipped from the beginning of the _output_ file
# before streaming is started, length is length of the song
# in seconds (or zero). All other possible arguments must
# be ignored. The resulting wav file (or the rest of
# the file after initial seek) is written to the standard
# output by the ssc_prog program. This is typically
# a script that is a front end for different conversion tools
# handling different formats.
#
#ssc_prog /etc/mt-daapd-ssc-script
#
# logfile (optional)
#
# This is the file to log to. If this is not configured,
# then it will log to the syslog.
#
# Not that the -d <level> switch will control the log verbosity.
# By default, it runs at log level 1. Log level 9 will churn
# out scads of useless debugging information. Values in between
# will vary the amount of logging you get.
#
#logfile /var/log/mt-daapd.log
#
# art_filename (optional)
#
# There is experimental support thanks to Hiren Joshi
# (hirenj@mooh.org) for dynamically adding art to the id3v2
# header as it is streamed (!!). If you were using a music system
# like zina or andromeda, for example, with cover art called
# "_folderOpenImage.jpg", you could use the parameter
# art_file _folderOpenImage.jpg and if the file _folderOpenImage.jpg
# was located in the same folder as the .mp3 file, it would appear
# in iTunes. Cool, eh?
#
#art_filename _folderOpenImage.jpg
#
# rescan_interval
#
# How often to check the file system (in sec) to see if any mp3 files
# have been added or removed.
#
# if not specified, the default is 0, which disables background scanning.
#
# If background rescanning is disabled, a scan can still be forced from the
# "status" page of the administrative web interface
#
# Setting a rescan_interval lower than the time it takes to rescan
# won't hurt anything, it will just waste CPU, and make connect times
# to the daap server longer.
#
#
rescan_interval = 600
# always_scan
#
# The default behavior is not not do background rescans of the
# filesystem unless there are clients connected. The thought is to
# allow the drives to spin down unless they are in use. This might be
# of more importance in IDE drives that aren't designed to be run
# 24x7. Forcing a scan through the web interface will always work
# though, even if no users are connected.
always_scan = 1
#
# process_m3u
#
# By default m3u processing is turned off, since most m3u files
# sitting around in peoples mp3 directories have bad paths, and
# I hear about it. :)
#
# If you are sure your m3u files have good paths (i.e. unixly pathed,
# with relative paths relative to the directory the m3u is in), then
# you can turn on m3u processing by setting this directive to 1.
#
# I'm not sure "unixly" is a word, but you get the idea.
#
process_m3u = 1
#
# scan_type
#
#
# This sets how aggressively mp3 files should be scanned to determine
# file length. There are three values:
#
# 0 (Normal)
# Just scan the first mp3 frame to try and calculate size. This will
# be accurate for most files, but VBR files without an Xing tag will
# probably have wildly inaccurate file times. This is the default.
#
# 1 (Aggressive)
# This checks the bitrates of 10 frames in the middle of the song.
# This will still be inaccurate for VBR files without an Xing tag,
# but they probably won't be quite as inaccurate as 0. This takes
# more time, obviously, although the time hit will only happen the
# first time you scan a particular file.
#
# 2 (Painfully aggressive)
# This walks through the entire song, counting the number of frames.
# This should result in accurate song times, but will take the most
# time. Again, this will only have to be incurred the first time
# the file is indexed.
#
scan_type=2
# compress 0
#
# Truncate
#
# should the server truncate the log files on startup.
# Defaults to zero
truncate = 1
[plugins]
plugin_dir = plugins
plugins = rsp.dll,w32-event.dll

View File

@ -1,662 +0,0 @@
; $Id$
; Script generated by the HM NIS Edit Script Wizard.
; Update for Vista
RequestExecutionLevel admin
; HM NIS Edit Wizard helper defines
!define PRODUCT_NAME "Firefly Media Server"
!define PRODUCT_SERVICE "Firefly Media Server"
!define /date DATEVER "%Y%m%d"
!define PRODUCT_VERSION "svn-$WCREV$"
!define PRODUCT_PUBLISHER "Ron Pedde"
!define PRODUCT_WEB_SITE "http://www.fireflymediaserver.org"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\firefly.exe"
!define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
!define PRODUCT_UNINST_ROOT_KEY "HKLM"
!define PROJROOT "..\..\.."
!define MTDROOT "..\.."
!define MTD_SOURCE "${MTDROOT}\win32\Release"
!define CONFIG_SOURCE "${MTDROOT}\win32\FireflyShell\Release"
!define DLL_SOURCE "${PROJROOT}\win32\dll"
!define ADMIN_ROOT "${MTDROOT}\admin-root"
!define REDIST_SOURCE "${PROJROOT}\win32\redist"
!include "FileFunc.nsh"
!insertmacro GetParameters
!insertmacro GetOptionsS
; MUI 1.67 compatible ------
!include "MUI.nsh"
; MUI Settings
;!define MUI_WELCOMEFINISHPAGE_BITMAP "ffsetup4.bmp"
!define MUI_ABORTWARNING
!define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico"
!define MUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall.ico"
; Welcome page
!insertmacro MUI_PAGE_WELCOME
; License page
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE LicensePost
!insertmacro MUI_PAGE_LICENSE "${ADMIN_ROOT}\gpl-license.txt"
; Directory page
!define MUI_PAGE_CUSTOMFUNCTION_PRE DirectoryPre
!define MUI_PAGE_CUSTOMFUNCTION_SHOW DirectoryShow
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE DirectoryLeave
!insertmacro MUI_PAGE_DIRECTORY
; Music Directory Page
!define MUI_PAGE_CUSTOMFUNCTION_PRE DirectoryPre
!define MUI_PAGE_CUSTOMFUNCTION_SHOW DirectoryShow
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE DirectoryLeave
!insertmacro MUI_PAGE_DIRECTORY
; Instfiles page
!insertmacro MUI_PAGE_INSTFILES
; Finish page
!insertmacro MUI_PAGE_FINISH
; Uninstaller pages
!insertmacro MUI_UNPAGE_INSTFILES
; MUI end ------
!macro LANG_LOAD LANGLOAD
!insertmacro MUI_LANGUAGE "${LANGLOAD}"
; !verbose
!include "localizations\${LANGLOAD}.nsh"
; !verbose on
!undef LANG
!macroend
!macro LANG_STRING NAME VALUE
LangString "${NAME}" "${LANG_${LANG}}" "${VALUE}"
!macroend
!macro LANG_UNSTRING NAME VALUE
!insertmacro LANG_STRING "un.${NAME}" "${VALUE}"
!macroend
!macro LANG_BOTHSTRING NAME VALUE
!insertmacro LANG_STRING "${NAME}" "${VALUE}"
!insertmacro LANG_UNSTRING "${NAME}" "${VALUE}"
!macroend
!insertmacro LANG_LOAD "English"
!insertmacro LANG_LOAD "French"
!insertmacro LANG_LOAD "Dutch"
!insertmacro LANG_LOAD "German"
!insertmacro LANG_LOAD "Japanese"
!insertmacro LANG_LOAD "Swedish"
!insertmacro LANG_LOAD "Italian"
Name "${PRODUCT_NAME}"
Icon "..\ff.ico"
UninstallIcon "..\ff.ico"
OutFile "${PRODUCT_NAME} (${PRODUCT_VERSION}).exe"
InstallDir "$PROGRAMFILES\${PRODUCT_NAME}\"
InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""
ShowInstDetails show
ShowUnInstDetails show
Section -Pre
!include WinMessages.nsh
FindWindow $0 "" "FireflyShellNotifyIconHidden"
SendMessage $0 ${WM_CLOSE} 0 0
nsSCM::QueryStatus "Bonjour Service"
Pop $0
Pop $1
StrCmp $0 "success" lbl_got_bonjour
MessageBox MB_OK "$(STRING_BONJOUR_ERROR)"
Quit
lbl_got_bonjour:
IntOp $9 0 + 0
nsSCM::QueryStatus "${PRODUCT_NAME}"
Pop $0
Pop $1
StrCmp $0 "success" lbl_stop_service
goto lbl_continue
lbl_stop_service:
DetailPrint "$(STRING_STOPPING_SERVICE)"
nsSCM::Stop "$(PRODUCT_NAME)"
lbl_wait_stop:
Sleep 1000
nsSCM::QueryStatus "$(PRODUCT_NAME)"
Pop $0
Pop $1
; DetailPrint $0
StrCmp $0 "success" lbl_check_status
goto lbl_continue
lbl_check_status:
IntCmp $1 1 lbl_continue lbl_wait_stop lbl_wait_stop
lbl_continue:
; should really loop until service stops...
DetailPrint "$(STRING_WAITING_FOR_STOP)"
IntOp $9 $9 + 1
IntCmp $9 10 +1 +1 lbl_done_pre
Sleep 1500
Delete $2\firefly.exe
IfErrors lbl_continue
lbl_done_pre:
SectionEnd
Section "MainSection" SEC01
SetOutPath "$2"
IfFileExists "$SMPROGRAMS\${PRODUCT_NAME}" HasProgramItems
goto NoProgramItems
HasProgramItems:
Delete "$SMPROGRAMS\${PRODUCT_NAME}\*"
NoProgramItems:
SetOverwrite on
File "${MTD_SOURCE}\firefly.exe"
File "${CONFIG_SOURCE}\FireflyShell.exe"
Delete "$2\FireflyShell.exe.manifest"
File "${CONFIG_SOURCE}\FireflyShell-0c.dll"
File "${CONFIG_SOURCE}\FireflyShell-07.dll"
File "${CONFIG_SOURCE}\FireflyShell-13.dll"
File "${CONFIG_SOURCE}\FireflyShell-1d.dll"
File "${CONFIG_SOURCE}\FireflyShell-11.dll"
File "${CONFIG_SOURCE}\FireflyShell-10.dll"
File "${CONFIG_SOURCE}\svcctrl.exe"
File "${DLL_SOURCE}\gnu_regex.dll"
File "${DLL_SOURCE}\pthreadVC2.dll"
File "${DLL_SOURCE}\sqlite.dll"
File "${DLL_SOURCE}\sqlite3.dll"
File "${DLL_SOURCE}\zlib1.dll"
File "${DLL_SOURCE}\avutil.dll"
File "${DLL_SOURCE}\avcodec.dll"
File "${DLL_SOURCE}\avformat.dll"
File "${DLL_SOURCE}\libFLAC.dll"
File "${DLL_SOURCE}\iconv.dll"
File "${DLL_SOURCE}\charset.dll"
SetOutPath "$2\plugins"
File "${MTD_SOURCE}\rsp.dll"
File "${MTD_SOURCE}\out-daap.dll"
File "${MTD_SOURCE}\w32-event.dll"
File "${MTD_SOURCE}\ssc-ffmpeg.dll"
File "${MTD_SOURCE}\ssc-wma.dll"
SetOutPath "$2\admin-root"
File "${ADMIN_ROOT}\thanks.html"
File "${ADMIN_ROOT}\about.html"
File "${ADMIN_ROOT}\status.js"
File "${ADMIN_ROOT}\smartpopup.html"
File "${ADMIN_ROOT}\smart.js"
File "${ADMIN_ROOT}\smart.html"
File "${ADMIN_ROOT}\required.gif"
File "${ADMIN_ROOT}\playlist.js"
File "${ADMIN_ROOT}\playlist.html"
File "${ADMIN_ROOT}\ff_logo_sm.gif"
File "${ADMIN_ROOT}\firefly.js"
File "${ADMIN_ROOT}\firefly.css"
File "${ADMIN_ROOT}\index.css"
File "${ADMIN_ROOT}\config.css"
File "${ADMIN_ROOT}\linkTransparent.gif"
File "${ADMIN_ROOT}\linkOpaque.gif"
File "${ADMIN_ROOT}\index.html"
File "${ADMIN_ROOT}\hdr.html"
File "${ADMIN_ROOT}\gpl-license.txt"
File "${ADMIN_ROOT}\gpl-license.html"
File "${ADMIN_ROOT}\ftr.html"
File "${ADMIN_ROOT}\feedback.html"
File "${ADMIN_ROOT}\favicon.ico"
File "${ADMIN_ROOT}\DAAPApplet-0.1.jar"
File "${ADMIN_ROOT}\CREDITS"
File "${ADMIN_ROOT}\config-update.html"
File "${ADMIN_ROOT}\config.html"
File "${ADMIN_ROOT}\config.js"
File "${ADMIN_ROOT}\config.xml"
File "${ADMIN_ROOT}\zlib-license.txt"
File "${ADMIN_ROOT}\zlib-license.html"
File "${ADMIN_ROOT}\xiph-license.txt"
File "${ADMIN_ROOT}\xiph-license.html"
File "${ADMIN_ROOT}\apache-2.0.txt"
File "${ADMIN_ROOT}\apache-2.0.html"
File "${ADMIN_ROOT}\applet.html"
File "${ADMIN_ROOT}\spinner.gif"
File "${ADMIN_ROOT}\spinner_stopped.gif"
File "${ADMIN_ROOT}\util.js"
File "${ADMIN_ROOT}\pngfix.js"
File "${ADMIN_ROOT}\no_access.html"
SetOutPath "$2\admin-root\lib-js"
File "${ADMIN_ROOT}\lib-js\prototype.js"
File "${ADMIN_ROOT}\lib-js\rico.js"
SetOutPath "$2\admin-root\lib-js\script.aculo.us"
File "${ADMIN_ROOT}\lib-js\script.aculo.us\builder.js"
File "${ADMIN_ROOT}\lib-js\script.aculo.us\controls.js"
File "${ADMIN_ROOT}\lib-js\script.aculo.us\dragdrop.js"
File "${ADMIN_ROOT}\lib-js\script.aculo.us\effects.js"
File "${ADMIN_ROOT}\lib-js\script.aculo.us\scriptaculous.js"
File "${ADMIN_ROOT}\lib-js\script.aculo.us\slider.js"
File "${ADMIN_ROOT}\lib-js\script.aculo.us\unittest.js"
SetOutPath "$2"
IfFileExists "$2\mapping.ini" HasMap
File "mapping.ini"
HasMap:
IfFileExists "$2\firefly.log" HasLog
File "firefly.log"
HasLog:
File "mt-daapd-example.conf"
IfFileExists "$2\mt-daapd.conf" HasConf
SetOverwrite off
CopyFiles "$2\mt-daapd-example.conf" "$2\mt-daapd.conf"
WriteINIStr "$2\mt-daapd.conf" "general" "mp3_dir" $3
HasConf:
WriteINIStr "$2\mt-daapd.conf" "plugins" "plugin_dir" "plugins"
WriteINIStr "$2\mt-daapd.conf" "plugins" "plugins" ""
ReadINIStr $0 "$2\mt-daapd.conf" "general" "rescan_interval"
StrCmp $0 "" rescan_set rescan_skip
rescan_set:
WriteINIStr "$2\mt-daapd.conf" "general" "rescan_interval" "600"
rescan_skip:
ReadINIStr $0 "$2\mt-daapd.conf" "general" "logfile"
StrCmp $0 "" logfile_set logfile_skip
logfile_set:
WriteINIStr "$2\mt-daapd.conf" "general" "logfile" "firefly.log"
logfile_skip:
; Check for default exts
ReadINIStr $0 "$2\mt-daapd.conf" "general" "extensions"
StrCmp $0 ".mp3,.m4a,.m4p" ext_set ext_skip
ext_set:
WriteINIStr "$2\mt-daapd.conf" "general" "extensions" ".mp3,.m4a,.m4p,.wma"
ext_skip:
; Check for truncate
ReadINIStr $0 "$2\mt-daapd.conf" "general" "truncate"
StrCmp $0 "" trunc_set trunc_skip
trunc_set:
WriteINIStr "$2\mt-daapd.conf" "general" "truncate" "1"
trunc_skip:
WriteINIStr "$2\mt-daapd.conf" "general" "db_type" "sqlite3"
AccessControl::SetOnFile "$2\mt-daapd.conf" "Everyone" "FullAccess"
AccessControl::SetOnFile "$2\mapping.ini" "Everyone" "FullAccess"
AccessControl::SetOnFile "$2\firefly.log" "Everyone" "FullAccess"
SetAutoClose False
SectionEnd
Section -AdditionalIcons
WriteIniStr "$2\${PRODUCT_NAME}.url" "InternetShortcut" "URL" "${PRODUCT_WEB_SITE}"
CreateDirectory "$SMPROGRAMS\${PRODUCT_NAME}"
CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\$(STRING_WEBSITE).lnk" "$2\${PRODUCT_NAME}.url"
CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\$(STRING_UNINSTALL).lnk" "$2\uninst.exe"
CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\$(STRING_DEBUG_MODE).lnk" "$2\firefly.exe" "-d9 -f"
CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\$(STRING_FF_CONFIGURATION).lnk" "$2\FireflyShell.exe"
CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\$(STRING_ADV_CONFIG).lnk" "notepad.exe" "$2\mt-daapd.conf"
Delete "$SMPROGRAMS\Startup\Firefly Configuration.lnk"
SectionEnd
!include "LogicLib.nsh"
!define UNINSTALL_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall"
!define APP_KEY "{A49F249F-0C91-497F-86DF-B2585E8E76B7}"
Section -VCRedistributable
ReadRegStr $R0 HKLM "${UNINSTALL_KEY}\${APP_KEY}\" "DisplayName"
${If} ${Errors}
# reg value doesn't exist (ie, needs installed)
SetOutPath "$2\"
File "${REDIST_SOURCE}\WindowsInstaller-KB893803-v2-x86.exe"
File "${REDIST_SOURCE}\VCRedist_x86.exe"
ExecWait '"$2\WindowsInstaller-KB893803-v2-x86.exe" /quiet /norestart'
ExecWait '"$2\VCRedist_x86.exe" /Q'
${EndIf}
SectionEnd
Section -Post
WriteUninstaller "$2\uninst.exe"
WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "$2\firefly.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "UninstallString" "$2\uninst.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayIcon" "$2\firefly.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayVersion" "${PRODUCT_VERSION}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "URLInfoAbout" "${PRODUCT_WEB_SITE}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}"
DeleteRegValue HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Run" "FireflyShell"
${GetParameters} $R0
ClearErrors
${GetOptionsS} $R0 "/N" $R1
IfErrors 0 +2 ; Skip the write if we have the /N option
WriteRegStr HKCU "SOFTWARE\Microsoft\Windows\CurrentVersion\Run" "FireflyShell" '"$2\FireflyShell.exe" -q'
; ExecWait "$2\firefly.exe -i"
nsSCM::Install "${PRODUCT_NAME}" "${PRODUCT_SERVICE}" 16 2 "$2\firefly.exe" "" "Bonjour Service" "" ""
Pop $0
Pop $1
StrCmp $0 "success" lbl_install_success
IntCmp $1 1073 lbl_install_success ; service already exists
MessageBox MB_OK "Error installing service: $1"
lbl_install_success:
; ExecWait 'netsh firewall add allowedprogram "$2\firefly.exe" "${PRODUCT_NAME}" enable'
; Use the SimpleFC plugin
SimpleFC::IsFirewallServiceRunning
Pop $0
Pop $1
intcmp $1 0 lbl_no_fw ; if 0, then skip fw config
SimpleFC::AddApplication "Firefly Media Server" "$2\Firefly.exe" 0 2 "" 1
lbl_no_fw:
nsSCM::Start "${PRODUCT_NAME}"
${GetParameters} $R0
ClearErrors
${GetOptionsS} $R0 "/N" $R1
IfErrors 0 +2 ; Skip the run if we have the /N option
Exec '"$2\FireflyShell.exe" -q'
SectionEnd
Function un.onUninstSuccess
HideWindow
MessageBox MB_ICONINFORMATION|MB_OK "$(un.STRING_UNINSTALLED)"
FunctionEnd
Function un.onInit
MessageBox MB_ICONQUESTION|MB_YESNO|MB_DEFBUTTON2 "$(un.STRING_AREYOUSURE)" IDYES +2
Abort
FunctionEnd
Function .onInit
; Must set $INSTDIR here to avoid adding ${PRODUCT_NAME} to the end of the
; path when user selects a new directory using the 'Browse' button.
StrCpy $INSTDIR "$PROGRAMFILES\${PRODUCT_NAME}"
StrCpy $2 "$PROGRAMFILES\${PRODUCT_NAME}"
StrCpy $3 "$DOCUMENTS\My Music"
IfSilent lbl_skip_lang
Push ""
Push ${LANG_ENGLISH}
Push English
Push ${LANG_FRENCH}
Push French
Push ${LANG_DUTCH}
Push Dutch
Push ${LANG_GERMAN}
Push German
Push ${LANG_JAPANESE}
Push Japanese
Push ${LANG_SWEDISH}
Push Swedish
Push ${LANG_ITALIAN}
Push Italian
; more
Push A
LangDLL::LangDialog "Installer Language" "Please select the language of the installer"
Pop $LANGUAGE
StrCmp $LANGUAGE "cancel" 0 +2
Abort
lbl_skip_lang:
FunctionEnd
Function LicensePost
StrCpy $9 "0"
FunctionEnd
Function DirectoryPre
StrCmp $9 "0" OK
;Skip 2nd (Music) Directory Page if conf file Exists
IfFileExists "$2\mt-daapd.conf" "" OK
Abort
OK:
FunctionEnd
Function DirectoryShow
StrCmp $9 "0" AppDirectoryPage
StrCmp $9 "1" MusicDirectoryPage
AppDirectoryPage:
StrCpy $9 "1"
!insertmacro MUI_INNERDIALOG_TEXT 1041 "$(STRING_DESTFOLDER)"
!insertmacro MUI_INNERDIALOG_TEXT 1019 "$PROGRAMFILES\${PRODUCT_NAME}\"
!insertmacro MUI_INNERDIALOG_TEXT 1006 "$(STRING_DESTDETAIL)"
Goto EndDirectoryShow
MusicDirectoryPage:
StrCpy $9 "2"
!insertmacro MUI_HEADER_TEXT "$(STRING_MUSICTITLE)" "$(STRING_MUSICHEADER)"
!insertmacro MUI_INNERDIALOG_TEXT 1041 "$(STRING_MUSICFOLDER)"
!insertmacro MUI_INNERDIALOG_TEXT 1019 "$DOCUMENTS\My Music"
!insertmacro MUI_INNERDIALOG_TEXT 1006 "$(STRING_MUSICDETAIL)"
EndDirectoryShow:
FunctionEnd
Function DirectoryLeave
StrCmp $9 "1" SaveInstallDir
StrCmp $9 "2" SaveMusicDir
Goto EndDirectoryLeave
SaveInstallDir:
StrCpy $2 $INSTDIR
Goto EndDirectoryLeave
SaveMusicDir:
; Push $INSTDIR
; Call GetParent
; Pop $3
StrCpy $3 $INSTDIR
EndDirectoryLeave:
FunctionEnd
Function .onVerifyInstDir
StrCmp $9 "2" DataPath All
DataPath:
;all valid if UNC
StrCpy $R2 $INSTDIR 2
StrCmp $R2 "\\" PathOK
All:
; Invalid path if root
Push $INSTDIR
call GetRoot
Pop $R1
StrCmp $R1 $INSTDIR "" PathOK
Abort
PathOK:
FunctionEnd
;--------------------------------
;Helper Functions
; GetParent
; input, top of stack (e.g. C:\Program Files\Poop)
; output, top of stack (replaces, with e.g. C:\Program Files)
; modifies no other variables.
;
; Usage:
; Push "C:\Program Files\Directory\Whatever"
; Call GetParent
; Pop $R0
; ; at this point $R0 will equal "C:\Program Files\Directory"
Function GetParent
Exch $R0
Push $R1
Push $R2
Push $R3
StrCpy $R1 0
StrLen $R2 $R0
loop:
IntOp $R1 $R1 + 1
IntCmp $R1 $R2 get 0 get
StrCpy $R3 $R0 1 -$R1
StrCmp $R3 "\" get
Goto loop
get:
StrCpy $R0 $R0 -$R1
Pop $R3
Pop $R2
Pop $R1
Exch $R0
FunctionEnd
Function GetRoot
Exch $0
Push $1
Push $2
Push $3
Push $4
StrCpy $1 $0 2
StrCmp $1 "\\" UNC
StrCpy $0 $1
Goto done
UNC:
StrCpy $2 3
StrLen $3 $0
loop:
IntCmp $2 $3 "" "" loopend
StrCpy $1 $0 1 $2
IntOp $2 $2 + 1
StrCmp $1 "\" loopend loop
loopend:
StrCmp $4 "1" +3
StrCpy $4 1
Goto loop
IntOp $2 $2 - 1
StrCpy $0 $0 $2
done:
Pop $4
Pop $3
Pop $2
Pop $1
Exch $0
FunctionEnd
Section Uninstall
SetAutoClose false
!include WinMessages.nsh
close_loop:
FindWindow $0 "" "FireflyShellNotifyIconHidden"
IntCmp $0 0 close_done
SendMessage $0 ${WM_QUIT} 0 0
SendMessage $0 ${WM_CLOSE} 0 0
SendMessage $0 ${WM_DESTROY} 0 0
Sleep 125
Goto close_loop
close_done:
IntOp $9 0 + 0
nsSCM::QueryStatus "${PRODUCT_NAME}"
Pop $0
Pop $1
StrCmp $0 "success" un_lbl_stop_service
goto un_lbl_continue
un_lbl_stop_service:
DetailPrint "$(STRING_STOPPING_SERVICE)"
nsSCM::Stop "$(PRODUCT_NAME)"
un_lbl_wait_stop:
Sleep 1000
nsSCM::QueryStatus "$(PRODUCT_NAME)"
Pop $0
Pop $1
; DetailPrint $0
StrCmp $0 "success" un_lbl_check_status
goto un_lbl_continue
un_lbl_check_status:
IntCmp $1 1 un_lbl_continue un_lbl_wait_stop un_lbl_wait_stop
un_lbl_continue:
; should really loop until service stops...
DetailPrint "$(STRING_WAITING_FOR_STOP)"
IntOp $9 $9 + 1
IntCmp $9 10 +1 +1 un_lbl_done_pre
Sleep 1500
Delete "$INSTDIR\firefly.exe"
IfErrors un_lbl_continue
un_lbl_done_pre:
Sleep 1000
nsSCM::Remove "${PRODUCT_NAME}"
Pop $0
StrCmp $0 "success" lbl_continue_uninstall
MessageBox MB_OK "Error Uninstalling service: $1"
lbl_continue_uninstall:
Delete "$INSTDIR\admin-root\lib-js\script.aculo.us\*"
RMDir "$INSTDIR\admin-root\lib-js\script.aculo.us"
Delete "$INSTDIR\admin-root\lib-js\*"
RMDir "$INSTDIR\admin-root\lib-js"
Delete "$INSTDIR\admin-root\*"
RMDir "$INSTDIR\admin-root"
Delete "$INSTDIR\plugins\*"
RMDir "$INSTDIR\plugins"
Delete "$INSTDIR\*"
RMDir "$INSTDIR"
Delete "$SMPROGRAMS\${PRODUCT_NAME}\*"
RMDir "$SMPROGRAMS\${PRODUCT_NAME}"
RMDir "$INSTDIR"
DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
DeleteRegKey HKLM "${PRODUCT_DIR_REGKEY}"
SetAutoClose false
SectionEnd

Binary file not shown.

View File

@ -1,4 +0,0 @@
LIBRARY out-daap
EXPORTS
plugin_info

View File

@ -1,103 +0,0 @@
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,0,0,$WCREV$
PRODUCTVERSION 1,0,0,$WCREV$
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x2L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "Comments", "http://www.fireflymediaserver.org"
VALUE "CompanyName", "Ron Pedde"
VALUE "FileDescription", "DAAP Output Plugin"
VALUE "FileVersion", "1.0 svn-$WCREV$"
VALUE "InternalName", "out-daap"
VALUE "LegalCopyright", "Copyright (C) 2006 Ron Pedde"
VALUE "OriginalFilename", "out-daap.dll"
VALUE "ProductName", "Firefly Media Server"
VALUE "ProductVersion", "1.0 svn-$WCREV$"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x409, 1200
END
END
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@ -1,243 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="out-daap"
ProjectGUID="{C1EF5133-DFB3-4FEC-B999-3655DBB14786}"
RootNamespace="out-daap"
Keyword="Win32Proj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="..\Debug"
IntermediateDirectory="Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..;..\..\src"
PreprocessorDefinitions="HAVE_CONFIG_H;WIN32"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="firefly.lib"
OutputFile="$(OutDir)/out-daap.dll"
LinkIncremental="2"
ModuleDefinitionFile="out-daap.def"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/out-daap.pdb"
SubSystem="2"
ImportLibrary="$(OutDir)/out-daap.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="..\Release"
IntermediateDirectory="Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..;..\..\src"
PreprocessorDefinitions="HAVE_CONFIG_H;WIN32"
RuntimeLibrary="0"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="..\firefly.lib"
OutputFile="$(OutDir)/out-daap.dll"
LinkIncremental="1"
ModuleDefinitionFile="out-daap.def"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ImportLibrary="$(OutDir)/out-daap.lib"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
>
<File
RelativePath="..\..\src\plugins\compat.c"
>
</File>
<File
RelativePath="..\..\src\plugins\out-daap-proto.c"
>
</File>
<File
RelativePath="..\..\src\plugins\out-daap.c"
>
</File>
<File
RelativePath=".\out-daap.def"
>
</File>
</Filter>
<Filter
Name="Header Files"
>
<File
RelativePath="..\..\src\compat.h"
>
</File>
<File
RelativePath="..\..\src\plugins\out-daap-db.h"
>
</File>
<File
RelativePath="..\..\src\plugins\out-daap-proto.h"
>
</File>
<File
RelativePath="..\..\src\plugins\out-daap.h"
>
</File>
<File
RelativePath=".\resource.h"
>
</File>
</Filter>
<Filter
Name="Resource Files"
>
<File
RelativePath=".\out-daap.rc"
>
</File>
</Filter>
<File
RelativePath="..\firefly.lib"
>
</File>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -1,14 +0,0 @@
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by out-daap.rc
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 101
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif

View File

@ -1,15 +0,0 @@
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by w32-event.rc
//
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 101
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif

Some files were not shown because too many files have changed in this diff Show More