+ final Context context = getListView().getContext();\r
+ final Dialog dialog = new Dialog(context);\r
+ dialog.setContentView(R.layout.about_dictionary_dialog);\r
+ final TextView textView = (TextView) dialog.findViewById(R.id.text);\r
+\r
+ final String name = application.getDictionaryName(dictFile.getName());\r
+ dialog.setTitle(name);\r
+ \r
+ final StringBuilder builder = new StringBuilder();\r
+ final DictionaryInfo dictionaryInfo = dictionary.getDictionaryInfo();\r
+ dictionaryInfo.uncompressedBytes = dictFile.length();\r
+ if (dictionaryInfo != null) {\r
+ builder.append(dictionaryInfo.dictInfo).append("\n\n");\r
+ builder.append(getString(R.string.dictionaryPath, dictFile.getPath())).append("\n");\r
+ builder.append(getString(R.string.dictionarySize, dictionaryInfo.uncompressedBytes)).append("\n");\r
+ builder.append(getString(R.string.dictionaryCreationTime, dictionaryInfo.creationMillis)).append("\n");\r
+ for (final IndexInfo indexInfo : dictionaryInfo.indexInfos) {\r
+ builder.append("\n");\r
+ builder.append(getString(R.string.indexName, indexInfo.shortName)).append("\n");\r
+ builder.append(getString(R.string.mainTokenCount, indexInfo.mainTokenCount)).append("\n");\r
+ }\r
+ builder.append("\n");\r
+ builder.append(getString(R.string.sources)).append("\n");\r
+ for (final EntrySource source : dictionary.sources) {\r
+ builder.append(getString(R.string.sourceInfo, source.getName(), source.getNumEntries())).append("\n");\r
+ }\r
+ }\r
+// } else {\r
+// builder.append(getString(R.string.invalidDictionary));\r
+// }\r
+ textView.setText(builder.toString());\r
+ \r
+ dialog.show();\r
+ final WindowManager.LayoutParams layoutParams = new WindowManager.LayoutParams();\r
+ layoutParams.width = WindowManager.LayoutParams.FILL_PARENT;\r
+ layoutParams.height = WindowManager.LayoutParams.FILL_PARENT;\r
+ dialog.getWindow().setAttributes(layoutParams);\r