This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

New sample

  • Loading branch information...
vladkorotnev committed Jul 15, 2011
1 parent c09e089 commit 60eb177048c181bf403a4902698efb5f662189af
Showing with 6 additions and 2 deletions.
  1. +1 −0 .gitignore
  2. +5 −2 Tweak.xm
  3. BIN obj/StartupSound.dylib
  4. BIN obj/Tweak.xm.o
  5. BIN sample2.wav
View
@@ -0,0 +1 @@
+.DS_Store
View
@@ -4,13 +4,16 @@
%hook SpringBoard
- (void)applicationDidFinishLaunching:(id)x {
%orig;
-
+ //startup sound
NSFileManager *fm=[NSFileManager defaultManager];
if([fm fileExistsAtPath:@"/var/mobile/startup.wav"]){
NSURL *newURL = [[NSURL alloc] initFileURLWithPath:@"/var/mobile/startup.wav"];
AVAudioPlayer *player = [[AVAudioPlayer alloc]initWithContentsOfURL:newURL error:nil];
[player prepareToPlay];
[player play];
+ [newURL release];
}
+ [fm release];
}
-%end
+
+%end
View
Binary file not shown.
View
Binary file not shown.
View
Binary file not shown.

0 comments on commit 60eb177

Please sign in to comment.