Commit fc551563 authored by Dimitrie O. Paun's avatar Dimitrie O. Paun Committed by Alexandre Julliard

Merge win.ini/[mci extensions] into the registry.

parent 19c36fe7
......@@ -35,6 +35,7 @@
#include "mmsystem.h"
#include "winuser.h"
#include "winnls.h"
#include "winreg.h"
#include "digitalv.h"
#include "winemm.h"
......@@ -185,13 +186,17 @@ const char* MCI_MessageToString(UINT16 wMsg)
static DWORD MCI_GetDevTypeFromFileName(LPCSTR fileName, LPSTR buf, UINT len)
{
LPSTR tmp;
HKEY hKey;
if ((tmp = strrchr(fileName, '.'))) {
GetProfileStringA("mci extensions", tmp + 1, "*", buf, len);
if (strcmp(buf, "*") != 0) {
return 0;
}
TRACE("No [mci extensions] entry for '%s' found.\n", tmp);
if (RegOpenKeyExA( HKEY_LOCAL_MACHINE, "SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\MCI Extensions",
0, KEY_QUERY_VALUE, &hKey ) == ERROR_SUCCESS) {
DWORD dwLen = len;
LONG lRet = RegQueryValueExA( hKey, tmp + 1, 0, 0, buf, &dwLen );
RegCloseKey( hKey );
if (lRet == ERROR_SUCCESS) return 0;
}
TRACE("No ...\\MCI Extensions entry for '%s' found.\n", tmp);
}
return MCIERR_EXTENSION_NOT_FOUND;
}
......
[mci extensions]
cda=cdaudio
mid=sequencer
midi=sequencer
rmi=sequencer
;aif=MPEGVideo
aifc=MPEGVideo
;aiff=MPEGVideo
asf=MPEGVideo2
asx=MPEGVideo2
au=MPEGVideo
;avi=MPEGVideo
lsf=MPEGVideo2
lsx=MPEGVideo2
m1v=MPEGVideo
m3u=MPEGVideo
;mov=MPEGVideo
m3u=MPEGVideo
mp2=MPEGVideo
mp2v=MPEGVideo
mp3=MPEGVideo
mpa=MPEGVideo
mpe=MPEGVideo
mpeg=MPEGVideo
mpg=MPEGVideo
mpv=MPEGVideo
mpv2=MPEGVideo
;qt=MPEGVideo
snd=MPEGVideo
rmi=MPEGVideo
;wav=MPEGVideo
wav=waveaudio
wax=MPEGVideo2
wm=MPEGVideo2
wma=MPEGVideo2
wmp=MPEGVideo2
wmv=MPEGVideo2
wmx=MPEGVideo2
wvx=MPEGVideo2
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment