# Resolving issues after removing most of JuceAppActivity.java parts

**URL:** <https://forum.juce.com/t/resolving-issues-after-removing-most-of-juceappactivity-java-parts/14300>\
**Category:** Android\
**Created:** [February 12, 2015, 3:56pm UTC](https://forum.juce.com/t/resolving-issues-after-removing-most-of-juceappactivity-java-parts/14300 "2015-02-12T15:56:01Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kanval\_Kalra](https://avatars.discourse-cdn.com/v4/letter/k/b3f665/32.png) [@Kanval\_Kalra](https://forum.juce.com/u/Kanval_Kalra)\
**Post date:** [February 12, 2015, 3:56pm UTC](https://forum.juce.com/t/resolving-issues-after-removing-most-of-juceappactivity-java-parts/14300/1 "2015-02-12T15:56:01Z")

</div>

Hi,

&nbsp;

Our application has been developed in iOS using JUCE. now we are trying to port the application to Android and we are facing issues. in our application we have employed JUCE for

1. Networking Operation

2. Sound Operations and Sound Manipulation

&nbsp;

we have no option of using&nbsp;JuceAppActivity.java because we are making a gaming application using unity and using JUCE to develop plugin for unity same as iOS one. in order to accomplish this goal we have altered the&nbsp;&nbsp;JuceAppActivity.java targeting JNI code in a way:

&nbsp;

// &nbsp; &nbsp;JUCEApplicationBase::createInstance = &juce\_CreateApplication;  
//  
// &nbsp; &nbsp;initialiseJuce\_GUI();  
//  
// &nbsp; &nbsp;JUCEApplicationBase\* app = JUCEApplicationBase::createInstance();  
// &nbsp; &nbsp;if (! app-\>initialiseApp())  
// &nbsp; &nbsp; &nbsp; &nbsp;exit (app-\>getApplicationReturnValue());  
//  
// &nbsp; &nbsp;jassert (MessageManager::getInstance()-\>isThisTheMessageThread());  
&nbsp;

//==============================================================================  
//#define JNI\_CLASS\_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \  
// METHOD (setViewName, &nbsp; "setViewName", &nbsp; &nbsp; &nbsp;"(Ljava/lang/String;)V") \  
// METHOD (layout, &nbsp; &nbsp; &nbsp; &nbsp;"layout", &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; "(IIII)V") \  
// METHOD (getLeft, &nbsp; &nbsp; &nbsp; "getLeft", &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;"()I") \  
// METHOD (getTop, &nbsp; &nbsp; &nbsp; &nbsp;"getTop", &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; "()I") \  
// METHOD (getWidth, &nbsp; &nbsp; &nbsp;"getWidth", &nbsp; &nbsp; &nbsp; &nbsp; "()I") \  
// METHOD (getHeight, &nbsp; &nbsp; "getHeight", &nbsp; &nbsp; &nbsp; &nbsp;"()I") \  
// METHOD (getLocationOnScreen, "getLocationOnScreen", "([I)V") \  
// METHOD (bringToFront, &nbsp;"bringToFront", &nbsp; &nbsp; "()V") \  
// METHOD (requestFocus, &nbsp;"requestFocus", &nbsp; &nbsp; "()Z") \  
// METHOD (setVisible, &nbsp; &nbsp;"setVisible", &nbsp; &nbsp; &nbsp; "(Z)V") \  
// METHOD (isVisible, &nbsp; &nbsp; "isVisible", &nbsp; &nbsp; &nbsp; &nbsp;"()Z") \  
// METHOD (hasFocus, &nbsp; &nbsp; &nbsp;"hasFocus", &nbsp; &nbsp; &nbsp; &nbsp; "()Z") \  
// METHOD (invalidate, &nbsp; &nbsp;"invalidate", &nbsp; &nbsp; &nbsp; "(IIII)V") \  
// METHOD (containsPoint, "containsPoint", &nbsp; &nbsp;"(II)Z") \  
// METHOD (showKeyboard, &nbsp;"showKeyboard", &nbsp; &nbsp; "(Ljava/lang/String;)V") \  
// METHOD (createGLView, &nbsp;"createGLView", &nbsp; &nbsp; "()L" JUCE\_ANDROID\_ACTIVITY\_CLASSPATH "$OpenGLView;") \  
//  
//DECLARE\_JNI\_CLASS (ComponentPeerView, JUCE\_ANDROID\_ACTIVITY\_CLASSPATH "$ComponentPeerView");  
//#undef JNI\_CLASS\_MEMBERS

now we have only commented these lines and its correcponding code as we found it was interacting with&nbsp;JuceAppActivity.java and we left everything else intact.

we have went through these articles :

http://www.juce.com/forum/topic/gui-less-android

http://www.juce.com/forum/topic/use-juces-audio-engine-non-gui-library

&nbsp;

we are facing app crashing so anyway this is possible. any help or direction will be greatly appreciated.&nbsp;

&nbsp;

Thank You

&nbsp;

&nbsp;

&nbsp;
