Skip to content

devbug/CCTogglesTemplates

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

#CCToggles

##Toggle and QuickLaunch template

###Files

CCTogglesAgent.h
nic/
	cctoggle_toggle.nic/
	cctoggle_toggle.nic.tar
QuickLaunches/
	AppSwitcher/
    InternalSettings/
Toggles/
	Respring/

#####THEOS nic You can use THEOS nic template.
Copy nic/cctoggle_toggle.nic.tar into $THEOS/templates/iphone/
And you can make CCToggles bundle by this command:

$THEOS/bin/nic.pl

#####Examples CCToggles has two sections.
Toggles and QuickLaunches.

They have just two differents.
Resources/Info.plist and
Makefile.


Before read below,
I just recommended if you want to make "Toggle", please use Flipswitch.

This is Toggle's Resources/Info.plist.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>CFBundleDevelopmentRegion</key>
	<string>English</string>
	<key>CFBundleExecutable</key>
	<string>Respring</string>
	<key>CFBundleIdentifier</key>
	<string>me.devbug.cctoggle.respring</string>
	<key>CFBundleDisplayName</key>
	<string>Respring</string>
	<key>CFBundleInfoDictionaryVersion</key>
	<string>6.0</string>
	<key>CFBundlePackageType</key>
	<string>BNDL</string>
	<key>CFBundleShortVersionString</key>
	<string>1.0.0</string>
	<key>CFBundleSignature</key>
	<string>????</string>
	<key>CFBundleVersion</key>
	<string>1.0</string>
	<key>DTPlatformName</key>
	<string>iphoneos</string>
	<key>MinimumOSVersion</key>
	<string>7.0</string>
	<key>NSPrincipalClass</key>
	<string>RespringCCToggle</string>
	<key>type</key>
	<string>Toggle</string>
	<key>wantsControlCenterDismissal</key>
	<false/>
	<key>wantsDeviceUnlock</key>
	<false/>
</dict>
</plist>



And this is QuickLaunch's Resources/Info.plist.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>CFBundleDevelopmentRegion</key>
	<string>English</string>
	<key>CFBundleExecutable</key>
	<string>AppSwitcher</string>
	<key>CFBundleIdentifier</key>
	<string>me.devbug.cctoggle.ql.appswitcher</string>
	<key>CFBundleDisplayName</key>
	<string>AppSwitcher</string>
	<key>CFBundleInfoDictionaryVersion</key>
	<string>6.0</string>
	<key>CFBundlePackageType</key>
	<string>BNDL</string>
	<key>CFBundleShortVersionString</key>
	<string>1.0.0</string>
	<key>CFBundleSignature</key>
	<string>????</string>
	<key>CFBundleVersion</key>
	<string>1.0</string>
	<key>DTPlatformName</key>
	<string>iphoneos</string>
	<key>MinimumOSVersion</key>
	<string>7.0</string>
	<key>NSPrincipalClass</key>
	<string>AppSwitcherCCToggle</string>
	<key>type</key>
	<string>QuickLaunch</string>
	<key>wantsControlCenterDismissal</key>
	<true/>
	<key>wantsDeviceUnlock</key>
	<false/>
</dict>
</plist>



If you make Toggle, you take care of these keys.

type, wantsControlCenterDismissal and wantsDeviceUnlock.

First of all, Toggle's wantsControlCenterDismissal is always false.
If you make QuickLaunch, you can set what you want.
wantsControlCenterDismissal means dismiss or not ControlCenter when you tap quicklaunch.

Toggle's wantsDeviceUnlock is also always false.

And type is just two values.
Toggle and QuickLaunch.
This is not important value.





This is Toggle's `Makefile`. ``` ARCHS = armv7 armv7s TARGET = iphone:clang::7.0 SDKVERSION = 7.0

include theos/makefiles/common.mk

BUNDLE_NAME = Respring Respring_FILES = Toggle.xm Respring_INSTALL_PATH = /Library/Application Support/CCToggles/Toggles

include $(THEOS_MAKE_PATH)/bundle.mk

<br />
And this is QuickLaunch's.

ARCHS = armv7 armv7s TARGET = iphone:clang::7.0 SDKVERSION = 7.0

include theos/makefiles/common.mk

BUNDLE_NAME = AppSwitcher AppSwitcher_FILES = Toggle.xm AppSwitcher_INSTALL_PATH = /Library/Application Support/CCToggles/QuickLaunches AppSwitcher_FRAMEWORKS = UIKit

include $(THEOS_MAKE_PATH)/bundle.mk

<br /><br />
I think I don't need more description of Makefile. :)<br />
<br /><br />
********************************************************************
<br /><br />
#####Icons
You should put icons at least two.<br />
For iPad 2 and iPad Mini<br />
`Icon.png`<br />
For iPhone 4/4s/5/5c/5s, iPod touch 5G, iPad 3/4/Air/Mini Retina<br />
`[email protected]`<br />
<br />
And if you want to set 'on' state icon, you should put one more pair.<br />
`Icon_on.png` and `[email protected]`.<br />
<br />
<br /><br />
********************************************************************
<br /><br />
#####Gestures
You can catch "double tap" and "long press" gestures.<br />
But I don't recommended using "double tap" gesture.<br />
<br />
And double tap gesture requires CCToggles (>= 0.1-16).<br />
※ long press gesture requires CCToggles (>= 0.1-6).<br />
<br />
Just add this methods<br />
  • (void)toggleLongPressed;
  • (void)toggleDoubleTapped;
<br />
<br /><br />
********************************************************************
<br /><br />
#####Localizations
Please see `Respring` Toggle's source code and *Resources* folder.<br />
<br /><br />



About

Templates and examples of CCToggles

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published