Closes #4
This commit is contained in:
parent
b3581d255c
commit
040c136746
|
@ -304,9 +304,11 @@ static void main_window_unload(Window *window) {
|
||||||
battery_state_service_unsubscribe();
|
battery_state_service_unsubscribe();
|
||||||
tick_timer_service_unsubscribe();
|
tick_timer_service_unsubscribe();
|
||||||
|
|
||||||
if (t) {
|
// Apparently, freeing this pointer causes the watchface to crash on
|
||||||
free(t);
|
// v3.3. Weird.
|
||||||
}
|
// if (t) {
|
||||||
|
// free(t);
|
||||||
|
// }
|
||||||
|
|
||||||
layer_destroy(s_battery_indicator_layer);
|
layer_destroy(s_battery_indicator_layer);
|
||||||
bitmap_layer_destroy(s_battery_icon_layer);
|
bitmap_layer_destroy(s_battery_icon_layer);
|
||||||
|
|
|
@ -19,9 +19,9 @@
|
||||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
* THE SOFTWARE.
|
* THE SOFTWARE.
|
||||||
*/
|
*/
|
||||||
Pebble.addEventListener('ready', function(e) {
|
// Pebble.addEventListener('ready', function(e) {
|
||||||
console.log('JS Ready!');
|
// console.log('JS Ready!');
|
||||||
});
|
// });
|
||||||
|
|
||||||
Pebble.addEventListener('showConfiguration', function(e) {
|
Pebble.addEventListener('showConfiguration', function(e) {
|
||||||
Pebble.openURL('https://pconf.bthlabs.pl/intuiclock/index.html');
|
Pebble.openURL('https://pconf.bthlabs.pl/intuiclock/index.html');
|
||||||
|
@ -29,7 +29,7 @@ Pebble.addEventListener('showConfiguration', function(e) {
|
||||||
|
|
||||||
Pebble.addEventListener('webviewclosed', function(e) {
|
Pebble.addEventListener('webviewclosed', function(e) {
|
||||||
var config_data = JSON.parse(decodeURIComponent(e.response));
|
var config_data = JSON.parse(decodeURIComponent(e.response));
|
||||||
console.log('Configuration page returned: ' + JSON.stringify(config_data));
|
// console.log('Configuration page returned: ' + JSON.stringify(config_data));
|
||||||
|
|
||||||
var dict = {};
|
var dict = {};
|
||||||
dict['KEY_SECONDS_HAND'] = config_data['seconds_hand'];
|
dict['KEY_SECONDS_HAND'] = config_data['seconds_hand'];
|
||||||
|
@ -37,8 +37,8 @@ Pebble.addEventListener('webviewclosed', function(e) {
|
||||||
dict['KEY_DATE_FORMAT'] = config_data['date_format'];
|
dict['KEY_DATE_FORMAT'] = config_data['date_format'];
|
||||||
|
|
||||||
Pebble.sendAppMessage(dict, function() {
|
Pebble.sendAppMessage(dict, function() {
|
||||||
console.log('Send successful!');
|
// console.log('Send successful!');
|
||||||
}, function() {
|
}, function() {
|
||||||
console.log('Send failed!');
|
// console.log('Send failed!');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue
Block a user