Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
abook_check
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abook_android
abook_check
Commits
d7557c42
Commit
d7557c42
authored
Jun 14, 2019
by
Lee Jaebin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#34085 【SATO android 1.0.0】オーサリングツールで作成した資料で文字化けが発生することがある
parent
824568a6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
3 deletions
+23
-3
ABVJE_BL/src/jp/agentec/adf/util/FileUtil.java
+22
-2
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/OperationListActivity.java
+1
-1
No files found.
ABVJE_BL/src/jp/agentec/adf/util/FileUtil.java
View file @
d7557c42
package
jp
.
agentec
.
adf
.
util
;
import
java.io.BufferedReader
;
import
java.io.File
;
import
java.io.FileFilter
;
import
java.io.FileInputStream
;
...
...
@@ -855,13 +856,32 @@ public class FileUtil {
return
null
;
// TODO: later 暫定処置 とりあえずこのまま
// throw new FileNotFoundException(path);
}
return
readTextFile
(
new
FileInputStream
(
file
));
return
readTextFile
(
new
BufferedReader
(
new
InputStreamReader
(
new
FileInputStream
(
file
),
"UTF-8"
)));
}
public
static
String
readTextFile
(
BufferedReader
bufferedReader
)
throws
IOException
{
StringBuffer
text
=
new
StringBuffer
();
try
{
String
readStr
;
while
((
readStr
=
bufferedReader
.
readLine
())
!=
null
)
{
text
.
append
(
readStr
);
}
return
text
.
toString
();
}
finally
{
if
(
bufferedReader
!=
null
)
{
try
{
bufferedReader
.
close
();
}
catch
(
Exception
e2
)
{
}
}
}
}
public
static
String
readTextFile
(
InputStream
is
)
throws
IOException
{
StringBuffer
text
=
new
StringBuffer
();
try
{
int
bufferSize
=
2048
;
int
bufferSize
=
2048
;
int
readSize
;
byte
[]
buffer
=
new
byte
[
bufferSize
];
while
((
readSize
=
is
.
read
(
buffer
,
0
,
buffer
.
length
))
>
0
)
{
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/OperationListActivity.java
View file @
d7557c42
...
...
@@ -205,7 +205,7 @@ public class OperationListActivity extends ABVUIActivity {
protected
void
onCreate
(
Bundle
savedInstanceState
)
{
super
.
onCreate
(
savedInstanceState
);
setContentView
(
R
.
layout
.
ac_operation_list
);
mListHelper
=
new
OperationListHelper
(
this
);
;
mListHelper
=
new
OperationListHelper
(
this
);
mViewModeButton
=
(
ImageButton
)
findViewById
(
R
.
id
.
btn_view_mode
);
mSearchButton
=
(
ImageButton
)
findViewById
(
R
.
id
.
btn_search
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment