Improve dmg cosmetics
This commit is contained in:
parent
441343538a
commit
d02a5ff57f
|
|
@ -103,3 +103,14 @@ if(NOT "$ENV{APPLE_CERTIFICATE_ID}" STREQUAL "")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(CPACK_GENERATOR "DragNDrop")
|
set(CPACK_GENERATOR "DragNDrop")
|
||||||
|
|
||||||
|
set(CPACK_DMG_VOLUME_NAME "${PROJECT_NAME} Installer")
|
||||||
|
set(CPACK_DMG_BACKGROUND_IMAGE "${CMAKE_SOURCE_DIR}/misc/macos-dmg-background.png")
|
||||||
|
|
||||||
|
configure_file(
|
||||||
|
"${CMAKE_SOURCE_DIR}/misc/macos-dmg-setup.applescript.in"
|
||||||
|
"${CMAKE_BINARY_DIR}/macos-dmg-setup.applescript"
|
||||||
|
@ONLY
|
||||||
|
)
|
||||||
|
|
||||||
|
set(CPACK_DMG_DS_STORE_SETUP_SCRIPT "${CMAKE_BINARY_DIR}/macos-dmg-setup.applescript")
|
||||||
|
|
|
||||||
BIN
misc/macos-dmg-background.png
Normal file
BIN
misc/macos-dmg-background.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 6.3 KiB |
32
misc/macos-dmg-setup.applescript.in
Normal file
32
misc/macos-dmg-setup.applescript.in
Normal file
|
|
@ -0,0 +1,32 @@
|
||||||
|
tell application "Finder"
|
||||||
|
tell disk "@CPACK_DMG_VOLUME_NAME@"
|
||||||
|
open
|
||||||
|
set current view of container window to icon view
|
||||||
|
set toolbar visible of container window to false
|
||||||
|
set statusbar visible of container window to false
|
||||||
|
set bounds of container window to {100, 100, 600, 500}
|
||||||
|
|
||||||
|
set viewOptions to the icon view options of container window
|
||||||
|
set arrangement of viewOptions to not arranged
|
||||||
|
set icon size of viewOptions to 96
|
||||||
|
|
||||||
|
try
|
||||||
|
set background picture of viewOptions to file ".background:background.png"
|
||||||
|
end try
|
||||||
|
|
||||||
|
set position of item "@CLIENT_NAME@.app" to {100, 80}
|
||||||
|
set position of item "Applications" to {400, 80}
|
||||||
|
|
||||||
|
set position of item "@SERVER_NAME@" to {100, 260}
|
||||||
|
set position of item "@BASEGAME@" to {250, 260}
|
||||||
|
|
||||||
|
if exists item "missionpack" then
|
||||||
|
set position of item "missionpack" to {400, 260}
|
||||||
|
end if
|
||||||
|
|
||||||
|
close
|
||||||
|
open
|
||||||
|
update without registering applications
|
||||||
|
delay 1
|
||||||
|
end tell
|
||||||
|
end tell
|
||||||
Loading…
Reference in New Issue
Block a user