#include <zxing/BinaryBitmap.h>\r
#include <CameraImage.h>\r
#include <string>\r
+#include <aknmessagequerydialog.h>\r
+#include "ZXingBarcodeReader_0xEF24C10A.rsg"\r
\r
using namespace zxing;\r
using namespace zxing::qrcode;\r
}\r
catch(zxing::Exception& e)\r
{\r
- string string = "Error...retrying...";\r
+ /*string string = "Error...retrying...";\r
HBufC8 *pHeap8 = HBufC8::NewMaxLC(string.size());\r
pHeap8->Des().Copy((const TUint8 *)string.c_str());\r
\r
HBufC *pHeap16 = HBufC::NewMaxLC(pHeap8->Length());\r
pHeap16->Des().Copy(*pHeap8);\r
\r
- ShowResultL(*pHeap16);\r
+ ShowResultL(*pHeap16);*/\r
}\r
}\r
\r
void CZXingBarcodeReaderAppView::ShowResultL(TDesC16& message)\r
{\r
- if (!iNote)\r
- {\r
- // Create the note once\r
- iNote = CAknInfoPopupNoteController::NewL();\r
- }\r
- // Hide the note. The last note may be visible when creating the second\r
- iNote->HideInfoPopupNote();\r
-\r
- // Set the time delay period before the popup is shown (in milliseconds)\r
- iNote->SetTimeDelayBeforeShow(100);\r
-\r
- // Set the time period of how long the popup is in the view (in milliseconds)\r
- iNote->SetTimePopupInView(2*1000);\r
-\r
- // Note text\r
- iNote->SetTextL(message);\r
+ StopTimer();\r
+ \r
+ CAknMessageQueryDialog* dlg = new (ELeave) CAknMessageQueryDialog ();\r
\r
- TRect rect(Rect());\r
+ dlg->PrepareLC(R_TEXT_QUERY_DIALOG );\r
+ \r
+ //HBufC* title = NULL; \r
+ //title = iEikonEnv->AllocReadResourceLC ( TEXT_DIALOG_TITLE );\r
+ dlg->QueryHeading ()->SetTextL (_L("Information") );\r
+ \r
+ dlg->SetMessageTextL ( message );\r
\r
- // Note position\r
- iNote->SetPositionAndAlignment(TPoint(rect.Width()/5,rect.Height()/7),EHLeftVTop);\r
-\r
- // Show note\r
- iNote->ShowInfoPopupNote();\r
+ dlg->RunLD();\r
+ \r
+ CleanupStack::PopAndDestroy();\r
+ \r
+ StartTimer();\r
}\r