OK, I've fixed it.
Just for future reference for anyone that may have the same problem,
I'll describe my solution.
In your AndroidManifest.xml file, make sure that you write the whole
package name of your custom class. Make also sure that there is
another intent action listed other than MAIN.
For example:
<activity android:name="com.android.settings.sip.SipSettings"
android:label="@string/sipSettings_menu_sipSettings"
>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<action
android:name="com.android.settings.SIP_SETTINGS" />
<category
android:name="android.intent.category.DEFAULT" />
<category
android:name="android.intent.category.VOICE_LAUNCH" />
</intent-filter>
</activity>
Then, in the preference screen that you are going to call this, call
it by the other action. Mine was at the front settings screen (that
uses the /res/xml/settings.xml file for its layout):
<PreferenceScreen
android:title="@string/sipSettings_menu_sipSettings"
android:summary="@string/
sipSettings_menu_sipSettingsDescription">
<intent
android:action="android.intent.action.SIP_SETTINGS"
android:targetPackage="com.android.settings"
android:targetClass="com.android.settings.sip.SipSettings" />
</PreferenceScreen>
Then it works. Maybe there is a bug in here somewhere, Google?