0

I have searched everywhere for a solution to this but cannot find one.

My tweak, developed in Theos is very simple, I want to disable the mute button in the phone app. I have found the private framework I think I need and the code that is called.

I have added a message so i can see if this routine is called, but is not.

Although my code compiles and installs on the phone, it never runs.

I have tried a basic springboard tweak and that is fine, so I must be doing something wrong with the framework or subroutine called?

(I have also added com.apple.mobilephone to my plist as suggested somewhere)

Here is my MAKEFILE

include theos/makefiles/common.mk
TARGET_IPHONEOS_DEPLOYMENT_VERSION=7.0
TWEAK_NAME = Disablemute
TARGET = iphone:7.0:7.0
ARCHS = armv7
Disablemute_FILES = Tweak.xm
Disablemute_FRAMEWORKS = UIKit
Disablemute_PRIVATE_FRAMEWORKS = TelephonyUtilities CoreTelephony
include $(THEOS_MAKE_PATH)/tweak.mk

Here is the tweak.mk code

#import <PrivateFrameworks/TelephonyUtilities/TUCall.h>
#import <UIKit/UIKit.h>

%hook TUCall

- (void)setMuted:(BOOL)arg1 {
//%orig;
%log;
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Welcome" 
    message:@"Welcome to your iPhone Burt!"
    delegate:nil 
    cancelButtonTitle:@"Thanks" 
    otherButtonTitles:nil];
[alert show];
[alert release];
}

%end

So the private framework is TelephonyUtilities and the header file is TUCall.h, the function is -void SetMuted:(BOOL)arg1;

Can anyone help please.

John Clifford
  • 16
  • 1
  • 5
  • Try hooking into the phone app instead and override the corresponding method. – 0xcaff Jan 17 '14 at 05:39
  • ok I have looked into doing this, but cannot find a list of methods that i could hook? I am not really sure how to hook into the phone app itself. – John Clifford Jan 18 '14 at 00:03
  • Currently there isn't a good place where all the private frameworks and core apps are documented. To find a list of methods to hook into you will need to dump the header files with class-dump. If you need help or pointers tweet @martincharles07 – 0xcaff Jan 18 '14 at 21:06
  • Thank you for your replies, I have done more research and see how to progress now. – John Clifford Jan 19 '14 at 11:12

0 Answers0