Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lib_base
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
sikang
lib_base
Commits
52862173
Commit
52862173
authored
Dec 13, 2018
by
sikang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug修复
parent
90bfd08e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
4 deletions
+14
-4
src/main/java/tech/starwin/mvp/ui/activity/TakePhotoActivity.java
+11
-0
src/main/java/tech/starwin/utils/collection/UploadManager.java
+3
-4
No files found.
src/main/java/tech/starwin/mvp/ui/activity/TakePhotoActivity.java
View file @
52862173
...
@@ -24,6 +24,7 @@ import tech.starwin.base.BaseActivity;
...
@@ -24,6 +24,7 @@ import tech.starwin.base.BaseActivity;
import
tech.starwin.impl.OnEventClickListener
;
import
tech.starwin.impl.OnEventClickListener
;
import
tech.starwin.utils.BitmapUtils
;
import
tech.starwin.utils.BitmapUtils
;
import
tech.starwin.utils.FileUtils
;
import
tech.starwin.utils.FileUtils
;
import
tech.starwin.utils.collection.UploadManager
;
import
tech.starwin.utils.context_utils.ActivityJumper
;
import
tech.starwin.utils.context_utils.ActivityJumper
;
import
tech.starwin.utils.context_utils.EasyActivityResult
;
import
tech.starwin.utils.context_utils.EasyActivityResult
;
import
tech.starwin.utils.ui_utils.UIHelper
;
import
tech.starwin.utils.ui_utils.UIHelper
;
...
@@ -131,7 +132,11 @@ public class TakePhotoActivity extends BaseActivity {
...
@@ -131,7 +132,11 @@ public class TakePhotoActivity extends BaseActivity {
@Override
@Override
protected
void
onStart
()
{
protected
void
onStart
()
{
super
.
onStart
();
super
.
onStart
();
try
{
cameraView
.
start
();
cameraView
.
start
();
}
catch
(
Exception
e
){
UploadManager
.
uploadException
(
e
,
"camera start exception"
);
}
}
}
@Override
@Override
...
@@ -142,7 +147,13 @@ public class TakePhotoActivity extends BaseActivity {
...
@@ -142,7 +147,13 @@ public class TakePhotoActivity extends BaseActivity {
@Override
@Override
protected
void
onStop
()
{
protected
void
onStop
()
{
super
.
onStop
();
super
.
onStop
();
try
{
cameraView
.
stop
();
cameraView
.
stop
();
}
catch
(
Exception
e
){
UploadManager
.
uploadException
(
e
,
"camera stop exception"
);
}
}
}
@Override
@Override
...
...
src/main/java/tech/starwin/utils/collection/UploadManager.java
View file @
52862173
...
@@ -150,11 +150,10 @@ public class UploadManager {
...
@@ -150,11 +150,10 @@ public class UploadManager {
}
catch
(
IOException
e
)
{
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
uploadException
(
e
,
e
.
getMessage
());
throw
new
RuntimeException
(
e
.
getMessage
());
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
throw
new
RuntimeException
(
e
.
getMessage
());
uploadException
(
e
,
e
.
getMessage
());
}
finally
{
}
finally
{
try
{
try
{
os
.
close
();
os
.
close
();
...
@@ -312,7 +311,7 @@ public class UploadManager {
...
@@ -312,7 +311,7 @@ public class UploadManager {
sendControlCommand
(
os
,
"CLOSE"
,
sessionId
,
"exception upload completed"
);
sendControlCommand
(
os
,
"CLOSE"
,
sessionId
,
"exception upload completed"
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
throw
new
RuntimeException
(
e
);
uploadException
(
e
,
e
.
getMessage
()
);
}
finally
{
}
finally
{
try
{
try
{
if
(
os
!=
null
)
{
if
(
os
!=
null
)
{
...
...
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