The opening code for launching an app?

Discussion in 'iOS Jailbreak & Cydia' started by CocaCola, Jun 15, 2010.

  1. CocaCola

    CocaCola New Member

    Joined:
    Jun 27, 2009
    Messages:
    783
    Likes Received:
    0
    Device:
    2G iPod touch
    I'd like to know where I can find the exact code for closing springboard and preparing to run the app.

    It's part of a troubleshooting option I'm working on.

    Thank you,
    - Coke
  2. Axis

    Axis Super Moderator Staff Member

    Joined:
    Dec 2, 2007
    Messages:
    6,288
    Likes Received:
    133
    Device:
    iPhone 4S (White)
    What exactly do you want? Obj-C code to launch an app?
  3. CocaCola

    CocaCola New Member

    Joined:
    Jun 27, 2009
    Messages:
    783
    Likes Received:
    0
    Device:
    2G iPod touch
    Yes. I suppose you could call it the launch sequence (for lack of a better term).

    As I'm not a developer or a good Object C writer, I'm not sure how or where to get this info.

    Thank you for the fast response.
  4. Axis

    Axis Super Moderator Staff Member

    Joined:
    Dec 2, 2007
    Messages:
    6,288
    Likes Received:
    133
    Device:
    iPhone 4S (White)
    There a few ways to launch an installed application. When I get to my Mac machine in a few minutes I can go through my dumped headers and give you the exact methods.

    Are you writing a program? What do you need them for?
  5. CocaCola

    CocaCola New Member

    Joined:
    Jun 27, 2009
    Messages:
    783
    Likes Received:
    0
    Device:
    2G iPod touch
    Yeah, I suppose you could call it a program.

    1.) You launch this false app with no real data or images.
    2.) The app crashes (intentionally and safely).
    3.) Springboard comes back up.

    It's like a lite respring. I'm having an issue with the pogoplank wheel sometimes not appearing, and launching an app and closing it a second later fixes the issue. An app that closes immediately after springboard closes would have the same effect while saving time and memory.
    It's more of a proof of concept deal than anything.
  6. SkylarEC

    SkylarEC Super Moderator Emeritus Staff Member

    Joined:
    Sep 19, 2007
    Messages:
    6,642
    Likes Received:
    129
    It's not just code. You also have to give your application the necessary entitlements to open another application.

    HTML:
    <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
    <plist version="1.0">
    <dict>
    	<key>application-identifier</key>
    	<string>com.yourapp.name</string>
    	<key>com.apple.springboard.launchapplications</key>
    	<true/>
    </dict>
    </plist>
  7. CocaCola

    CocaCola New Member

    Joined:
    Jun 27, 2009
    Messages:
    783
    Likes Received:
    0
    Device:
    2G iPod touch
    Yeah, I know. I can handle most of the other stuff. I have a hommie who can help me out, but he needs a new battery for his laptop and until then he is "powerless".

    Thank you very much.
  8. wyndwarrior

    wyndwarrior Active Member

    Joined:
    Jun 8, 2009
    Messages:
    1,433
    Likes Received:
    1
    Device:
    3G iPod touch
    Why not just make an app that terminates itself? If all you want is to make it return to springboard, not launch another app.
  9. CocaCola

    CocaCola New Member

    Joined:
    Jun 27, 2009
    Messages:
    783
    Likes Received:
    0
    Device:
    2G iPod touch
    That's what I'm doing.

    It'll have just enough data to be recognized as an app, and all it will do is close itself.

Share This Page