Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
halo
packages_apps_Bluetooth
Commits
20844c45
Commit
20844c45
authored
15 years ago
by
Jaikumar Ganesh
Committed by
Android (Google) Code Review
15 years ago
Browse files
Options
Download
Plain Diff
Merge "Not update TransferActivity button during activity creating."
parents
304373d3
0e927e91
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
4 deletions
+9
-4
src/com/android/bluetooth/opp/BluetoothOppTransferActivity.java
...m/android/bluetooth/opp/BluetoothOppTransferActivity.java
+9
-4
No files found.
src/com/android/bluetooth/opp/BluetoothOppTransferActivity.java
View file @
20844c45
...
...
@@ -113,6 +113,10 @@ public class BluetoothOppTransferActivity extends AlertActivity implements
/** Observer to get notified when the content observer's data changes */
private
BluetoothTransferContentObserver
mObserver
;
// do not update button during activity creating, only update when db
// changes after activity created
private
boolean
mNeedUpdateButton
=
false
;
private
class
BluetoothTransferContentObserver
extends
ContentObserver
{
public
BluetoothTransferContentObserver
()
{
super
(
new
Handler
());
...
...
@@ -121,6 +125,7 @@ public class BluetoothOppTransferActivity extends AlertActivity implements
@Override
public
void
onChange
(
boolean
selfChange
)
{
if
(
V
)
Log
.
v
(
TAG
,
"received db changes."
);
mNeedUpdateButton
=
true
;
updateProgressbar
();
}
}
...
...
@@ -245,6 +250,8 @@ public class BluetoothOppTransferActivity extends AlertActivity implements
customizeViewContent
();
// no need update button when activity creating
mNeedUpdateButton
=
false
;
updateProgressbar
();
return
mView
;
...
...
@@ -435,12 +442,10 @@ public class BluetoothOppTransferActivity extends AlertActivity implements
// DIALOG_RECEIVE_COMPLETE_SUCCESS/DIALOG_RECEIVE_COMPLETE_FAIL
// Handle the case when DIALOG_SEND_ONGOING evolve to
// DIALOG_SEND_COMPLETE_SUCCESS/DIALOG_SEND_COMPLETE_FAIL
if
(!
mIsComplete
&&
BluetoothShare
.
isStatusCompleted
(
mTransInfo
.
mStatus
)
)
{
if
(!
mIsComplete
&&
BluetoothShare
.
isStatusCompleted
(
mTransInfo
.
mStatus
)
&&
mNeedUpdateButton
)
{
displayWhichDialog
();
updateButton
();
customizeViewContent
();
}
}
...
...
This diff is collapsed.
Click to expand it.
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