Check-in [233d1929c2]
Overview
Comment:ChromeOS: Made PIN entry failure code slightly cleaner
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:233d1929c28893e43dd31b9c264ec96053130e48
User & Date: rkeene on 2016-02-13 10:08:53
Other Links: manifest | tags
Context
2016-02-13
10:09
ChromeOS: Whitespace cleanup check-in: 78f6a43a4e user: rkeene tags: trunk
10:08
ChromeOS: Made PIN entry failure code slightly cleaner check-in: 233d1929c2 user: rkeene tags: trunk
10:05
ChromeOS: Made PIN entry dialog much more robust check-in: 2c6a5fb7dd user: rkeene tags: trunk
Changes

Modified build/chrome/cackey.js from [5dbcaf75a3] to [e6983d567a].

   128    128   				 * Register a handler to handle the window being closed without
   129    129   				 * having sent anything
   130    130   				 */
   131    131   				pinWindow.onClosed.addListener(function() {
   132    132   					if (pinWindowDidWork != 1) {
   133    133   						console.log("[cackey] The PIN dialog was closed without resubmitting the request, treating it as a failure");
   134    134   
   135         -						cackeyMessageIncoming(
   136         -							{
   137         -								"data": {
   138         -									"target": "cackey",
   139         -									"command": messageEvent.data.command,
   140         -									"id": messageEvent.data.id,
   141         -									"status": "error",
   142         -									"error": "PIN window closed without a PIN being provided"
   143         -								}
   144         -							}
   145         -						)
          135  +						messageEvent.data.status = "error";
          136  +						messageEvent.data.error = "PIN window closed without a PIN being provided";
   146    137   
          138  +						cackeyMessageIncoming(messageEvent);
   147    139   					}
          140  +
   148    141   					return;
   149    142   				})
   150    143   
   151    144   				/*
   152    145   				 * Pass this message off to the other window so that it may resubmit the request.
   153    146   				 */
   154    147   				pinWindow.contentWindow.parentWindow = window;