@@ -270,6 +270,11 @@ public static string[] DCCVendorLocations {
270
270
locationsList . Add ( locations [ i ] ) ;
271
271
}
272
272
}
273
+ //If we found anything, just return the list
274
+ if ( locationsList . Count > 0 )
275
+ {
276
+ return locationsList . ToArray ( ) ;
277
+ }
273
278
}
274
279
275
280
//Check the surrounding area around MAYA_LOCATION for any other Applications we may want.
@@ -289,7 +294,7 @@ public static string[] DCCVendorLocations {
289
294
290
295
//If we found 'Maya.app' in the location string, we're going to trim it and everything after it out.
291
296
//This way our possibleLocation will be more uniform between windows and mac.
292
-
297
+
293
298
//make sure we found "maya.app."
294
299
if ( appIndex >= 0 )
295
300
{
@@ -302,7 +307,7 @@ public static string[] DCCVendorLocations {
302
307
{
303
308
possibleLocation = parentDirectory . ToString ( ) ;
304
309
}
305
- }
310
+ }
306
311
}
307
312
308
313
if ( ! string . IsNullOrEmpty ( possibleLocation ) && Directory . Exists ( possibleLocation ) )
@@ -311,17 +316,14 @@ public static string[] DCCVendorLocations {
311
316
}
312
317
}
313
318
314
- if ( locationsList . Count > 0 )
315
- {
316
- return locationsList . ToArray ( ) ;
317
- }
318
-
319
319
switch ( Application . platform )
320
320
{
321
321
case RuntimePlatform . WindowsEditor :
322
- return new string [ ] { "C:/Program Files/Autodesk" , "D:/Program Files/Autodesk" } ;
322
+ locationsList . AddRange ( new string [ ] { "C:/Program Files/Autodesk" , "D:/Program Files/Autodesk" } ) ;
323
+ return locationsList . ToArray ( ) ;
323
324
case RuntimePlatform . OSXEditor :
324
- return new string [ ] { "/Applications/Autodesk" } ;
325
+ locationsList . AddRange ( new string [ ] { "/Applications/Autodesk" } ) ;
326
+ return locationsList . ToArray ( ) ;
325
327
default :
326
328
throw new NotImplementedException ( ) ;
327
329
}
0 commit comments