home *** CD-ROM | disk | FTP | other *** search
/ Freelog 115 / FreelogNo115-MaiJuin2013.iso / Internet / Firefox / FirefoxPortable_20.0_French.paf.exe / Other / Source / CheckForPlatformSplashDisable.nsh < prev    next >
Text File  |  2010-06-22  |  2KB  |  56 lines

  1. ∩╗┐; CheckForPlatformSplashDisable 1.0 (2010-06-16)
  2. ;
  3. ; Checks if the platform wants the splash screen disabled
  4. ; Copyright 2008-2010 John T. Haller of PortableApps.com
  5. ; Released under the GPL
  6. ;
  7. ; Usage: ${CheckForPlatformSplashDisable} _v
  8. ;
  9. ; Example: ${CheckForPlatformSplashDisable} $DISABLESPLASHSCREEN
  10. ;    If the platform wants it disabled, $DISABLESPLASHSCREEN will be true.
  11. ;    Otherwise it will be whatever its previous value was
  12.  
  13. !macro CheckForPlatformSplashDisable _v
  14.     StrCmp ${_v} true _CFPSDEnd
  15.         ;Get the parameter and sort out the stack
  16.         Push $0
  17.         Push $1
  18.         Push $R0
  19.         
  20.         StrCpy $0 ${_v}
  21.  
  22.         ;Read from the INI
  23.         ReadEnvStr $1 PortableApps.comDisableSplash
  24.         StrCmp $1 "true" "" _CFPSDStackEnd
  25.  
  26.         ${GetParent} $EXEDIR $1
  27.         IfFileExists $1\PortableApps.com\PortableAppsPlatform.exe "" _CFPSDStackEnd
  28.  
  29.         MoreInfo::GetProductName `$1\PortableApps.com\PortableAppsPlatform.exe`
  30.         Pop $R0
  31.         StrCmp $R0 "PortableApps.com Platform" "" _CFPSDStackEnd
  32.  
  33.         MoreInfo::GetCompanyName `$1\PortableApps.com\PortableAppsPlatform.exe`
  34.         Pop $R0
  35.         StrCmp $R0 PortableApps.com "" _CFPSDStackEnd
  36.  
  37.         !ifdef NSIS_UNICODE
  38.         FindProc $R0 PortableAppsPlatform.exe
  39.         !else
  40.         FindProcDLL::FindProc PortableAppsPlatform.exe ; Onto $R0
  41.         !endif
  42.         IntCmp $R0 1 "" _CFPSDStackEnd _CFPSDStackEnd
  43.  
  44.         StrCpy $0 true
  45.  
  46.         _CFPSDStackEnd:
  47.         ; Restore the stack and sort everything out
  48.         Pop $R0
  49.         Pop $1
  50.         Exch $0
  51.         Pop ${_v}
  52.  
  53.     _CFPSDEnd:
  54. !macroend
  55. !define CheckForPlatformSplashDisable '!insertmacro CheckForPlatformSplashDisable'
  56.