equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #include "helpfile.h" |
|
20 #include <f32file.h> |
|
21 #include <e32std.h> |
|
22 #include <pls.h> // For emulator WSD API |
|
23 #include <glib.h> |
|
24 |
|
25 extern "C" char* libgstreamer_get_dll_path(char* dllName) |
|
26 { |
|
27 TUint ch = TUint('A'); |
|
28 char* fullPath = dllName; |
|
29 #ifdef __WINSCW__ |
|
30 char* dllPath = "z:\\sys\\bin\\plugins"; |
|
31 fullPath = g_strjoin ("\\", dllPath,dllName, NULL); |
|
32 #else |
|
33 char* dllPath = "sys\\bin"; |
|
34 |
|
35 char* filename; |
|
36 TInt i; |
|
37 RFs fs; |
|
38 TDriveList driveList; |
|
39 //err = fs.Connect(); |
|
40 if( !(fs.Connect()) ) |
|
41 { |
|
42 //err = fs.DriveList(driveList); |
|
43 if( !(fs.DriveList(driveList)) ) |
|
44 { |
|
45 for( i = 0; i< KMaxDrives; i++ ) |
|
46 { |
|
47 |
|
48 if( driveList[i] != 0 ) |
|
49 { |
|
50 char temp[3]; |
|
51 temp[0]= char(ch); |
|
52 temp[1]= ':'; |
|
53 temp[2]= '\0'; |
|
54 |
|
55 filename = g_strjoin ("\\", temp,dllPath,dllName, NULL); |
|
56 if (g_file_test (filename, G_FILE_TEST_EXISTS)) |
|
57 { |
|
58 fullPath = filename; |
|
59 break; |
|
60 } |
|
61 } |
|
62 ch++; |
|
63 } |
|
64 } |
|
65 fs.Close(); |
|
66 } |
|
67 #endif |
|
68 return fullPath; |
|
69 } |
|
70 |