| Index: printing/printing_context_android.cc
|
| diff --git a/printing/printing_context_android.cc b/printing/printing_context_android.cc
|
| index 64139c8bfb837c708d0002bf4f85ff707a28e44e..58426f60a805cb07822061533a2fe05910f39278 100644
|
| --- a/printing/printing_context_android.cc
|
| +++ b/printing/printing_context_android.cc
|
| @@ -79,6 +79,12 @@ PrintingContextAndroid::PrintingContextAndroid(Delegate* delegate)
|
| PrintingContextAndroid::~PrintingContextAndroid() {
|
| }
|
|
|
| +void PrintingContextAndroid::SetPrintSettingsCallback(
|
| + const PrintSettingsCallback& callback) {
|
| + LOG(INFO) << "DGN - Set cb - this: " << this << ", callback_: " << &callback;
|
| + callback_ = callback;
|
| +}
|
| +
|
| void PrintingContextAndroid::AskUserForSettings(
|
| int max_pages,
|
| bool has_selection,
|
| @@ -93,6 +99,8 @@ void PrintingContextAndroid::AskUserForSettings(
|
| reinterpret_cast<intptr_t>(this)));
|
| }
|
|
|
| + LOG(INFO) << "DGN - AskUserForSettings - this: " << this
|
| + << ", callback_: " << &callback;
|
| Java_PrintingContext_pageCountEstimationDone(env,
|
| j_printing_context_.obj(),
|
| max_pages);
|
| @@ -104,9 +112,12 @@ void PrintingContextAndroid::AskUserForSettingsReply(JNIEnv* env,
|
| if (!success) {
|
| // TODO(cimamoglu): Differentiate between FAILED And CANCEL.
|
| callback_.Run(FAILED);
|
| + LOG(INFO) << "DGN - AskUserForSettingsReply - FAILED or CANCEL";
|
| return;
|
| }
|
|
|
| + LOG(INFO) << "DGN - AskUserForSettingsReply - SUCCESS";
|
| +
|
| // We use device name variable to store the file descriptor. This is hacky
|
| // but necessary. Since device name is not necessary for the upstream
|
| // printing code for Android, this is harmless.
|
| @@ -132,6 +143,13 @@ void PrintingContextAndroid::AskUserForSettingsReply(JNIEnv* env,
|
| callback_.Run(OK);
|
| }
|
|
|
| +void PrintingContextAndroid::ShowSystemDialogDone(JNIEnv* env,
|
| + jobject obj) {
|
| + LOG(INFO) << "DGN - ShowSystemDialogDone - Running callback with 'TEST'";
|
| + LOG(INFO) << "DGN - this: " << this << ", callback_: " << &callback_;
|
| + callback_.Run(TEST);
|
| +}
|
| +
|
| PrintingContext::Result PrintingContextAndroid::UseDefaultSettings() {
|
| DCHECK(!in_print_job_);
|
|
|
|
|