[Sony Cross-Device Development Themes and Apps] wolfmannight:
Guide:

Changes in SettingsActivity.smali

add line below [ invoke-static {p0, v0, p1}, Lcom/android/settings/SettingsActivity;->loadCategoriesFromResource(ILjava/util/List;)V ]

.line 1030
const v0, 0x7f080065

invoke-static {p0, v0, p1}, Lcom/sonymobile/settings/SomcDashboardTiles;->loadTilesFromResource(Lcom/android/settings/SettingsActivity;ILjava/util/List;)V

above 0x7f080065 is public.xml id of [ somc_add_dashboard_tiles ]

<public type="xml" name="somc_add_dashboard_tiles" id="0x7f080065" />

------------------

change [ invoke-static to invoke-virtual ]

invoke-virtual {p0, v0, p1}, Lcom/android/settings/SettingsActivity;->loadCategoriesFromResource(ILjava/util/List;)V

--------------------------

Replace this code with full method [ .method public loadCategoriesFromResource(ILjava/util/List;)V ]

.method public loadCategoriesFromResource(ILjava/util/List;)V
.locals 22
.param p1, "resid" # I
.annotation system Ldalvik/annotation/Signature;
value = {
"(I",
"Ljava/util/List",
"<",
"Lcom/android/settings/dashboard/DashboardCategory;",
">;)V"
}
.end annotation

.prologue
.line 990
.local p2, "target":Ljava/util/List;, "Ljava/util/List<Lcom/android/settings/dashboard/DashboardCategory;>;"
const/4 v12, 0x0

.line 992
.local v12, "parser":Landroid/content/res/XmlResourceParser;
:try_start_0
invoke-virtual/range {p0 .. p0}, Lcom/android/settings/SettingsActivity;->getResources()Landroid/content/res/Resources;

move-result-object v17

move-object/from16 v0, v17

move/from16 v1, p1

invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getXml(I)Landroid/content/res/XmlResourceParser;

move-result-object v12

.line 993
invoke-static {v12}, Landroid/util/Xml;->asAttributeSet(Lorg/xmlpull/v1/XmlPullParser;)Landroid/util/AttributeSet;

move-result-object v2

.line 997
.local v2, "attrs":Landroid/util/AttributeSet;
:cond_0
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->next()I

move-result v16

.local v16, "type":I
const/16 v17, 0x1

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_1

const/16 v17, 0x2

move/from16 v0, v16

move/from16 v1, v17

if-ne v0, v1, :cond_0

.line 1001
:cond_1
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getName()Ljava/lang/String;

move-result-object v10

.line 1002
.local v10, "nodeName":Ljava/lang/String;
const-string v17, "dashboard-categories"

move-object/from16 v0, v17

invoke-virtual {v0, v10}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v17

if-nez v17, :cond_3

.line 1003
new-instance v17, Ljava/lang/RuntimeException;

new-instance v18, Ljava/lang/StringBuilder;

invoke-direct/range {v18 .. v18}, Ljava/lang/StringBuilder;-><init>()V

const-string v19, "XML document must start with <preference-categories> tag; found"

invoke-virtual/range {v18 .. v19}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

move-result-object v18

move-object/from16 v0, v18

invoke-virtual {v0, v10}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

move-result-object v18

const-string v19, " at "

invoke-virtual/range {v18 .. v19}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

move-result-object v18

invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getPositionDescription()Ljava/lang/String;

move-result-object v19

invoke-virtual/range {v18 .. v19}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

move-result-object v18

invoke-virtual/range {v18 .. v18}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

move-result-object v18

invoke-direct/range {v17 .. v18}, Ljava/lang/RuntimeException;-><init>(Ljava/lang/String;)V

throw v17
:try_end_0
.catch Lorg/xmlpull/v1/XmlPullParserException; {:try_start_0 .. :try_end_0} :catch_0
.catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_1
.catchall {:try_start_0 .. :try_end_0} :catchall_0

.line 1123
.end local v2 # "attrs":Landroid/util/AttributeSet;
.end local v10 # "nodeName":Ljava/lang/String;
.end local v16 # "type":I
:catch_0
move-exception v5

.line 1124
.local v5, "e":Lorg/xmlpull/v1/XmlPullParserException;
:try_start_1
new-instance v17, Ljava/lang/RuntimeException;

const-string v18, "Error parsing categories"

move-object/from16 v0, v17

move-object/from16 v1, v18

invoke-direct {v0, v1, v5}, Ljava/lang/RuntimeException;-><init>(Ljava/lang/String;Ljava/lang/Throwable;)V

throw v17
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0

.line 1128
.end local v5 # "e":Lorg/xmlpull/v1/XmlPullParserException;
:catchall_0
move-exception v17

if-eqz v12, :cond_2

invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->close()V

:cond_2
throw v17

.line 1008
.restart local v2 # "attrs":Landroid/util/AttributeSet;
.restart local v10 # "nodeName":Ljava/lang/String;
.restart local v16 # "type":I
:cond_3
const/4 v4, 0x0

.line 1010
.local v4, "curBundle":Landroid/os/Bundle;
:try_start_2
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getDepth()I

move-result v11

.line 1012
.local v11, "outerDepth":I
:cond_4
:goto_0
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->next()I

move-result v16

const/16 v17, 0x1

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_19

const/16 v17, 0x3

move/from16 v0, v16

move/from16 v1, v17

if-ne v0, v1, :cond_5

invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getDepth()I

move-result v17

move/from16 v0, v17

if-le v0, v11, :cond_19

.line 1013
:cond_5
const/16 v17, 0x3

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_4

const/16 v17, 0x4

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_4

.line 1017
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getName()Ljava/lang/String;

move-result-object v10

.line 1018
const-string v17, "dashboard-category"

move-object/from16 v0, v17

invoke-virtual {v0, v10}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v17

if-eqz v17, :cond_18

.line 1019
new-instance v3, Lcom/android/settings/dashboard/DashboardCategory;

invoke-direct {v3}, Lcom/android/settings/dashboard/DashboardCategory;-><init>()V

.line 1021
.local v3, "category":Lcom/android/settings/dashboard/DashboardCategory;
sget-object v17, Lcom/android/internal/R$styleable;->PreferenceHeader:[I

move-object/from16 v0, p0

move-object/from16 v1, v17

invoke-virtual {v0, v2, v1}, Lcom/android/settings/SettingsActivity;->obtainStyledAttributes(Landroid/util/AttributeSet;[I)Landroid/content/res/TypedArray;

move-result-object v13

.line 1023
.local v13, "sa":Landroid/content/res/TypedArray;
const/16 v17, 0x1

const/16 v18, -0x1

move/from16 v0, v17

move/from16 v1, v18

invoke-virtual {v13, v0, v1}, Landroid/content/res/TypedArray;->getResourceId(II)I

move-result v17

move/from16 v0, v17

int-to-long v0, v0

move-wide/from16 v18, v0

move-wide/from16 v0, v18

iput-wide v0, v3, Lcom/android/settings/dashboard/DashboardCategory;->id:J

.line 1027
const/16 v17, 0x2

move/from16 v0, v17

invoke-virtual {v13, v0}, Landroid/content/res/TypedArray;->peekValue(I)Landroid/util/TypedValue;

move-result-object v15

.line 1029
.local v15, "tv":Landroid/util/TypedValue;
if-eqz v15, :cond_6

iget v0, v15, Landroid/util/TypedValue;->type:I

move/from16 v17, v0

const/16 v18, 0x3

move/from16 v0, v17

move/from16 v1, v18

if-ne v0, v1, :cond_6

.line 1030
iget v0, v15, Landroid/util/TypedValue;->resourceId:I

move/from16 v17, v0

if-eqz v17, :cond_e

.line 1031
iget v0, v15, Landroid/util/TypedValue;->resourceId:I

move/from16 v17, v0

move/from16 v0, v17

iput v0, v3, Lcom/android/settings/dashboard/DashboardCategory;->titleRes:I

.line 1036
:cond_6
:goto_1
invoke-virtual {v13}, Landroid/content/res/TypedArray;->recycle()V

.line 1038
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getDepth()I

move-result v6

.line 1040
.local v6, "innerDepth":I
:cond_7
:goto_2
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->next()I

move-result v16

const/16 v17, 0x1

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_17

const/16 v17, 0x3

move/from16 v0, v16

move/from16 v1, v17

if-ne v0, v1, :cond_8

invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getDepth()I

move-result v17

move/from16 v0, v17

if-le v0, v6, :cond_17

.line 1041
:cond_8
const/16 v17, 0x3

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_7

const/16 v17, 0x4

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_7

.line 1045
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getName()Ljava/lang/String;

move-result-object v8

.line 1046
.local v8, "innerNodeName":Ljava/lang/String;
const-string v17, "dashboard-tile"

move-object/from16 v0, v17

invoke-virtual {v8, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v17

if-eqz v17, :cond_16

.line 1047
new-instance v14, Lcom/android/settings/dashboard/DashboardTile;

invoke-direct {v14}, Lcom/android/settings/dashboard/DashboardTile;-><init>()V

.line 1049
.local v14, "tile":Lcom/android/settings/dashboard/DashboardTile;
sget-object v17, Lcom/android/internal/R$styleable;->PreferenceHeader:[I

move-object/from16 v0, p0

move-object/from16 v1, v17

invoke-virtual {v0, v2, v1}, Lcom/android/settings/SettingsActivity;->obtainStyledAttributes(Landroid/util/AttributeSet;[I)Landroid/content/res/TypedArray;

move-result-object v13

.line 1051
const/16 v17, 0x1

const/16 v18, -0x1

move/from16 v0, v17

move/from16 v1, v18

invoke-virtual {v13, v0, v1}, Landroid/content/res/TypedArray;->getResourceId(II)I

move-result v17

move/from16 v0, v17

int-to-long v0, v0

move-wide/from16 v18, v0

move-wide/from16 v0, v18

iput-wide v0, v14, Lcom/android/settings/dashboard/DashboardTile;->id:J

.line 1054
const/16 v17, 0x2

move/from16 v0, v17

invoke-virtual {v13, v0}, Landroid/content/res/TypedArray;->peekValue(I)Landroid/util/TypedValue;

move-result-object v15

.line 1056
if-eqz v15, :cond_9

iget v0, v15, Landroid/util/TypedValue;->type:I

move/from16 v17, v0

const/16 v18, 0x3

move/from16 v0, v17

move/from16 v1, v18

if-ne v0, v1, :cond_9

.line 1057
iget v0, v15, Landroid/util/TypedValue;->resourceId:I

move/from16 v17, v0

if-eqz v17, :cond_f

.line 1058
iget v0, v15, Landroid/util/TypedValue;->resourceId:I

move/from16 v17, v0

move/from16 v0, v17

iput v0, v14, Lcom/android/settings/dashboard/DashboardTile;->titleRes:I

.line 1063
:cond_9
:goto_3
const/16 v17, 0x3

move/from16 v0, v17

invoke-virtual {v13, v0}, Landroid/content/res/TypedArray;->peekValue(I)Landroid/util/TypedValue;

move-result-object v15

.line 1065
if-eqz v15, :cond_a

iget v0, v15, Landroid/util/TypedValue;->type:I

move/from16 v17, v0

const/16 v18, 0x3

move/from16 v0, v17

move/from16 v1, v18

if-ne v0, v1, :cond_a

.line 1066
iget v0, v15, Landroid/util/TypedValue;->resourceId:I

move/from16 v17, v0

if-eqz v17, :cond_10

.line 1067
iget v0, v15, Landroid/util/TypedValue;->resourceId:I

move/from16 v17, v0

move/from16 v0, v17

iput v0, v14, Lcom/android/settings/dashboard/DashboardTile;->summaryRes:I

.line 1072
:cond_a
:goto_4
const/16 v17, 0x0

const/16 v18, 0x0

move/from16 v0, v17

move/from16 v1, v18

invoke-virtual {v13, v0, v1}, Landroid/content/res/TypedArray;->getResourceId(II)I

move-result v17

move/from16 v0, v17

iput v0, v14, Lcom/android/settings/dashboard/DashboardTile;->iconRes:I

.line 1074
const/16 v17, 0x4

move/from16 v0, v17

invoke-virtual {v13, v0}, Landroid/content/res/TypedArray;->getString(I)Ljava/lang/String;

move-result-object v17

move-object/from16 v0, v17

iput-object v0, v14, Lcom/android/settings/dashboard/DashboardTile;->fragment:Ljava/lang/String;

.line 1076
invoke-virtual {v13}, Landroid/content/res/TypedArray;->recycle()V

.line 1078
if-nez v4, :cond_b

.line 1079
new-instance v4, Landroid/os/Bundle;

.end local v4 # "curBundle":Landroid/os/Bundle;
invoke-direct {v4}, Landroid/os/Bundle;-><init>()V

.line 1082
.restart local v4 # "curBundle":Landroid/os/Bundle;
:cond_b
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getDepth()I

move-result v7

.line 1084
.local v7, "innerDepth2":I
:cond_c
:goto_5
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->next()I

move-result v16

const/16 v17, 0x1

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_13

const/16 v17, 0x3

move/from16 v0, v16

move/from16 v1, v17

if-ne v0, v1, :cond_d

invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getDepth()I

move-result v17

move/from16 v0, v17

if-le v0, v7, :cond_13

.line 1085
:cond_d
const/16 v17, 0x3

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_c

const/16 v17, 0x4

move/from16 v0, v16

move/from16 v1, v17

if-eq v0, v1, :cond_c

.line 1089
invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->getName()Ljava/lang/String;

move-result-object v9

.line 1090
.local v9, "innerNodeName2":Ljava/lang/String;
const-string v17, "extra"

move-object/from16 v0, v17

invoke-virtual {v9, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v17

if-eqz v17, :cond_11

.line 1091
invoke-virtual/range {p0 .. p0}, Lcom/android/settings/SettingsActivity;->getResources()Landroid/content/res/Resources;

move-result-object v17

const-string v18, "extra"

move-object/from16 v0, v17

move-object/from16 v1, v18

invoke-virtual {v0, v1, v2, v4}, Landroid/content/res/Resources;->parseBundleExtra(Ljava/lang/String;Landroid/util/AttributeSet;Landroid/os/Bundle;)V

.line 1092
invoke-static {v12}, Lcom/android/internal/util/XmlUtils;->skipCurrentTag(Lorg/xmlpull/v1/XmlPullParser;)V
:try_end_2
.catch Lorg/xmlpull/v1/XmlPullParserException; {:try_start_2 .. :try_end_2} :catch_0
.catch Ljava/io/IOException; {:try_start_2 .. :try_end_2} :catch_1
.catchall {:try_start_2 .. :try_end_2} :catchall_0

goto :goto_5

.line 1125
.end local v2 # "attrs":Landroid/util/AttributeSet;
.end local v3 # "category":Lcom/android/settings/dashboard/DashboardCategory;
.end local v4 # "curBundle":Landroid/os/Bundle;
.end local v6 # "innerDepth":I
.end local v7 # "innerDepth2":I
.end local v8 # "innerNodeName":Ljava/lang/String;
.end local v9 # "innerNodeName2":Ljava/lang/String;
.end local v10 # "nodeName":Ljava/lang/String;
.end local v11 # "outerDepth":I
.end local v13 # "sa":Landroid/content/res/TypedArray;
.end local v14 # "tile":Lcom/android/settings/dashboard/DashboardTile;
.end local v15 # "tv":Landroid/util/TypedValue;
.end local v16 # "type":I
:catch_1
move-exception v5

.line 1126
.local v5, "e":Ljava/io/IOException;
:try_start_3
new-instance v17, Ljava/lang/RuntimeException;

const-string v18, "Error parsing categories"

move-object/from16 v0, v17

move-object/from16 v1, v18

invoke-direct {v0, v1, v5}, Ljava/lang/RuntimeException;-><init>(Ljava/lang/String;Ljava/lang/Throwable;)V

throw v17
:try_end_3
.catchall {:try_start_3 .. :try_end_3} :catchall_0

.line 1033
.end local v5 # "e":Ljava/io/IOException;
.restart local v2 # "attrs":Landroid/util/AttributeSet;
.restart local v3 # "category":Lcom/android/settings/dashboard/DashboardCategory;
.restart local v4 # "curBundle":Landroid/os/Bundle;
.restart local v10 # "nodeName":Ljava/lang/String;
.restart local v11 # "outerDepth":I
.restart local v13 # "sa":Landroid/content/res/TypedArray;
.restart local v15 # "tv":Landroid/util/TypedValue;
.restart local v16 # "type":I
:cond_e
:try_start_4
iget-object v0, v15, Landroid/util/TypedValue;->string:Ljava/lang/CharSequence;

move-object/from16 v17, v0

move-object/from16 v0, v17

iput-object v0, v3, Lcom/android/settings/dashboard/DashboardCategory;->title:Ljava/lang/CharSequence;

goto/16 :goto_1

.line 1060
.restart local v6 # "innerDepth":I
.restart local v8 # "innerNodeName":Ljava/lang/String;
.restart local v14 # "tile":Lcom/android/settings/dashboard/DashboardTile;
:cond_f
iget-object v0, v15, Landroid/util/TypedValue;->string:Ljava/lang/CharSequence;

move-object/from16 v17, v0

move-object/from16 v0, v17

iput-object v0, v14, Lcom/android/settings/dashboard/DashboardTile;->title:Ljava/lang/CharSequence;

goto/16 :goto_3

.line 1069
:cond_10
iget-object v0, v15, Landroid/util/TypedValue;->string:Ljava/lang/CharSequence;

move-object/from16 v17, v0

move-object/from16 v0, v17

iput-object v0, v14, Lcom/android/settings/dashboard/DashboardTile;->summary:Ljava/lang/CharSequence;

goto/16 :goto_4

.line 1094
.restart local v7 # "innerDepth2":I
.restart local v9 # "innerNodeName2":Ljava/lang/String;
:cond_11
const-string v17, "intent"

move-object/from16 v0, v17

invoke-virtual {v9, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v17

if-eqz v17, :cond_12

.line 1095
invoke-virtual/range {p0 .. p0}, Lcom/android/settings/SettingsActivity;->getResources()Landroid/content/res/Resources;

move-result-object v17

move-object/from16 v0, v17

invoke-static {v0, v12, v2}, Landroid/content/Intent;->parseIntent(Landroid/content/res/Resources;Lorg/xmlpull/v1/XmlPullParser;Landroid/util/AttributeSet;)Landroid/content/Intent;

move-result-object v17

move-object/from16 v0, v17

iput-object v0, v14, Lcom/android/settings/dashboard/DashboardTile;->intent:Landroid/content/Intent;

goto/16 :goto_5

.line 1098
:cond_12
invoke-static {v12}, Lcom/android/internal/util/XmlUtils;->skipCurrentTag(Lorg/xmlpull/v1/XmlPullParser;)V

goto/16 :goto_5

.line 1102
.end local v9 # "innerNodeName2":Ljava/lang/String;
:cond_13
invoke-virtual {v4}, Landroid/os/Bundle;->size()I

move-result v17

if-lez v17, :cond_14

.line 1103
iput-object v4, v14, Lcom/android/settings/dashboard/DashboardTile;->fragmentArguments:Landroid/os/Bundle;

.line 1104
const/4 v4, 0x0

.line 1108
:cond_14
iget-wide v0, v14, Lcom/android/settings/dashboard/DashboardTile;->id:J

move-wide/from16 v18, v0

const-wide/32 v20, 0x7f0f0241

cmp-long v17, v18, v20

if-nez v17, :cond_15

invoke-static/range {p0 .. p0}, Lcom/android/settings/Utils;->showSimCardTile(Landroid/content/Context;)Z

move-result v17

if-eqz v17, :cond_7

.line 1109
:cond_15
invoke-virtual {v3, v14}, Lcom/android/settings/dashboard/DashboardCategory;->addTile(Lcom/android/settings/dashboard/DashboardTile;)V

goto/16 :goto_2

.line 1113
.end local v7 # "innerDepth2":I
.end local v14 # "tile":Lcom/android/settings/dashboard/DashboardTile;
:cond_16
invoke-static {v12}, Lcom/android/internal/util/XmlUtils;->skipCurrentTag(Lorg/xmlpull/v1/XmlPullParser;)V

goto/16 :goto_2

.line 1117
.end local v8 # "innerNodeName":Ljava/lang/String;
:cond_17
move-object/from16 v0, p2

invoke-interface {v0, v3}, Ljava/util/List;->add(Ljava/lang/Object;)Z

goto/16 :goto_0

.line 1119
.end local v3 # "category":Lcom/android/settings/dashboard/DashboardCategory;
.end local v6 # "innerDepth":I
.end local v13 # "sa":Landroid/content/res/TypedArray;
.end local v15 # "tv":Landroid/util/TypedValue;
:cond_18
invoke-static {v12}, Lcom/android/internal/util/XmlUtils;->skipCurrentTag(Lorg/xmlpull/v1/XmlPullParser;)V
:try_end_4
.catch Lorg/xmlpull/v1/XmlPullParserException; {:try_start_4 .. :try_end_4} :catch_0
.catch Ljava/io/IOException; {:try_start_4 .. :try_end_4} :catch_1
.catchall {:try_start_4 .. :try_end_4} :catchall_0

goto/16 :goto_0

.line 1128
:cond_19
if-eqz v12, :cond_1a

invoke-interface {v12}, Landroid/content/res/XmlResourceParser;->close()V

.line 1130
:cond_1a
return-void
.end method

--------------------------------------------

add entry in public.xml

<public type="xml" name="somc_add_dashboard_tiles" id="0x7f080065" />

--------------------------------------------

put somc_add_dashboard_tiles.xml to /res/xml/

========================

Changes in SettingsPreferenceFragment.smali

first line should be

.class public Lcom/android/settings/SettingsPreferenceFragment;

remove "abstract" if it present in above line

---------------------------------------

Replace line like [ Lcom/android/settings/InstrumentedPreferenceFragment with Lcom/sonymobile/settings/preference/util/SomcSettingsPreferenceFragment; ]

it will after change look like this

.super Lcom/sonymobile/settings/preference/util/SomcSettingsPreferenceFragment;

in whole file change every [ Lcom/android/settings/InstrumentedPreferenceFragment with Lcom/sonymobile/settings/preference/util/SomcSettingsPreferenceFragment; ]

================================================================================================

add icon file and strings and id in xml

it will show you new list of missing things in xmls