Caio Marcelo de Oliveira Filho [Mon, 23 Sep 2013 17:18:12 +0000 (14:18 -0300)]
[Notification] Do not keep separated copy of notifications
Notification object is essentialy as a "property bag" to be used in
conjunction with tizen.notification.* functions. Now that we have
v8tools.forceSetProperty() we can keep certain properties read-only and
do not need to worry about user changing the notification, so no need to
keep our own copy of the data.
Note that since Notification API doesn't rely on GC to identify
notifications that should be removed, one needs to explicitly call the
remove function, or wait for user removal via the UI.
Caio Marcelo de Oliveira Filho [Mon, 23 Sep 2013 17:15:05 +0000 (14:15 -0300)]
[Notification] Create a function to extract properties
As we start to support more properties, the NOTIFICATION_PROPERTIES
array will get filled.
cmarcelo [Wed, 25 Sep 2013 20:51:02 +0000 (13:51 -0700)]
Merge pull request #180 from cmarcelo/enable-c++-0x
Enable -std=c++0x
Caio Marcelo de Oliveira Filho [Wed, 25 Sep 2013 17:21:20 +0000 (14:21 -0300)]
Enable -std=c++0x
Tizen 2.x compiler is g++ 4.5.3 which already support some of the C++11
features like 'auto' and lambdas. It is fine to use those features in
the extensions.
Unfortunately there's an issue when compiling code using bluetooth.h in
C++11, so it's it disable for the tizen_bluetooth extension for now.
cmarcelo [Tue, 24 Sep 2013 20:00:57 +0000 (13:00 -0700)]
Merge pull request #148 from lpereira/filesystem-api
Add Tizen Filesystem API.
Leandro Pereira [Mon, 26 Aug 2013 19:37:10 +0000 (16:37 -0300)]
Add Tizen Filesystem API.
This commit implements most of the Tizen Filesystem API.
Some things were intentionally left unimplemented, such as listing and
obtaining stoarage information. These will be implemented as soon as the
need to pass all TCT tests arise.
File I/O works, as evidenced by the new filesystem.html example (a crude
text editor) -- although this example doesn't showcase the whole API.
cmarcelo [Tue, 24 Sep 2013 19:02:24 +0000 (12:02 -0700)]
Merge pull request #178 from cmarcelo/tizen-using-cpp-wrapper
Tizen using cpp wrapper
Leandro A. F. Pereira [Tue, 24 Sep 2013 18:35:43 +0000 (11:35 -0700)]
Merge pull request #176 from ricardotk/wip
[Time] Add unicode timezone support and fix API
Caio Marcelo de Oliveira Filho [Tue, 24 Sep 2013 18:22:49 +0000 (15:22 -0300)]
[tizen] Fix JS coding style
Fixes #166.
Caio Marcelo de Oliveira Filho [Tue, 24 Sep 2013 18:01:48 +0000 (15:01 -0300)]
[tizen] Remove not used function
Caio Marcelo de Oliveira Filho [Tue, 24 Sep 2013 17:57:08 +0000 (14:57 -0300)]
[tizen] Use new C++ Wrapper instead of old ExtensionAdapter
Ricardo de Almeida Gonzaga [Mon, 23 Sep 2013 18:11:06 +0000 (15:11 -0300)]
[Time] Add unicode timezone support
Tizen uses unicode timezone to do timezone operations.
Ricardo de Almeida Gonzaga [Mon, 23 Sep 2013 16:50:50 +0000 (13:50 -0300)]
[Time] Fix toString getDay misunderstanding
getDay() returns the day of the week (0 - 6)
getDate() returns the day of the month (1 - 31)
Ricardo de Almeida Gonzaga [Mon, 23 Sep 2013 15:13:31 +0000 (12:13 -0300)]
[Time] Fix TimeDuration unit set property comparison
Kenneth Rohde Christiansen [Mon, 23 Sep 2013 22:34:11 +0000 (15:34 -0700)]
Merge pull request #173 from Ryan--Yang/master
[SystemInfo] fix JS code style
cmarcelo [Mon, 23 Sep 2013 17:26:25 +0000 (10:26 -0700)]
Merge pull request #175 from cmarcelo/cpp-wrapper
Add a more friendly C++ wrapper for our C API
Caio Marcelo de Oliveira Filho [Fri, 20 Sep 2013 16:31:15 +0000 (13:31 -0300)]
[Notification] Use new C++ wrapper in common/
NotificationExtension now hosts the NotificationManager for mobile and
passes to the instances. For convenience, two different instance
interfaces were created, one for Desktop other for Mobile.
Behavior should not change after this patch.
Caio Marcelo de Oliveira Filho [Fri, 20 Sep 2013 16:30:41 +0000 (13:30 -0300)]
[common] Create C++ wrapper to replace ExtensionAdapater
Current ExtensionAdapter ends up merging the concept of extension and
instance (before called Context) together, and this causes confusion
understanding the execution of the code.
The new approach is to create a C++ pair of classes that represent
Extension and Instance. This mimics what we have inside Crosswalk, and
also is pretty much the same approach PPAPI constructs its C++ API as
well.
One nice consequence is that the subclass of Extension can be used to
store objects shared by all instances -- since it have the correct
lifetime. We can get rid of most ad-hoc singleton implementations in the
code.
One downside is that we resort to virtual methods in this new
approach. Even though the overhead is low, if this proves to be a
bottleneck for a specific extension, it's easy to fallback to using the
C API directly instead of the convenience.
yangruiintel [Sun, 22 Sep 2013 02:28:08 +0000 (10:28 +0800)]
[SystemInfo] fix JS code style
cmarcelo [Fri, 20 Sep 2013 20:05:01 +0000 (13:05 -0700)]
Merge pull request #171 from darktears/power-isscreenon-fix
[Power] Fix a TCT failure with isScreenOn()
Alexis Menard [Fri, 20 Sep 2013 18:43:29 +0000 (15:43 -0300)]
[Power] Fix a TCT failure with isScreenOn()
TCT tests are expecting turnScreenOn/Off to have a synchronous behavior
which in fact means that querying the screen state right after should
return the correct value. In fact the underlaying platform does not
necessarily switch on or off the screen right away, it may take few
ms. This patch add a synchronous behavior to isScreenOn by
making sure to return when the platform informed us about the state
change of the screen (if called previously with turnScreenOn/Off).
This is slightly better than a busy wait.
cmarcelo [Fri, 20 Sep 2013 19:53:19 +0000 (12:53 -0700)]
Merge pull request #172 from cmarcelo/notification-cleanup
Notification cleanup
Caio Marcelo de Oliveira Filho [Fri, 20 Sep 2013 19:41:03 +0000 (16:41 -0300)]
[Notification] Fix JS style
Fixes #161.
Caio Marcelo de Oliveira Filho [Fri, 20 Sep 2013 19:33:05 +0000 (16:33 -0300)]
[Notification] Clean up example a bit
Jesus Sanchez-Palencia [Fri, 20 Sep 2013 13:51:10 +0000 (06:51 -0700)]
Merge pull request #170 from ricardotk/wip
[Time] Fix the style of Time API JS File using the new checking tool.
Ricardo de Almeida Gonzaga [Fri, 20 Sep 2013 13:38:37 +0000 (10:38 -0300)]
[Time] Fix the style of Time API JS File using the new checking tool.
Issue #165
Alexis Menard [Fri, 20 Sep 2013 12:28:54 +0000 (05:28 -0700)]
Merge pull request #169 from darktears/power-style-fix
Fix the style of the Power API JS file using the new checking tool.
Alexis Menard [Fri, 20 Sep 2013 12:07:50 +0000 (09:07 -0300)]
Fix the style of the Power API JS file using the new checking tool.
Issue #162
Kenneth Rohde Christiansen [Thu, 19 Sep 2013 23:20:59 +0000 (16:20 -0700)]
Merge pull request #168 from vcgomes/bluetooth-fix-invalid-access
bluetooth: Fix accessing invalid memory when creating the service proxy
Vinicius Costa Gomes [Thu, 19 Sep 2013 22:47:05 +0000 (19:47 -0300)]
bluetooth: Fix accessing invalid memory when creating the service proxy
Probably during one rebase, the change that added the GCancellable and its
wrapper helper function, was not propagated to this call. The callback
was expecting to find a GCancellable.
Jesus Sanchez-Palencia [Thu, 19 Sep 2013 22:26:32 +0000 (15:26 -0700)]
Merge pull request #167 from jeez/fix
[Bluetooth] Fix object property
Jesus Sanchez-Palencia [Thu, 19 Sep 2013 22:20:30 +0000 (19:20 -0300)]
[Bluetooth] Fix object property
Kenneth Rohde Christiansen [Thu, 19 Sep 2013 21:14:09 +0000 (14:14 -0700)]
Merge pull request #158 from ricardotk/wip
Fix Time API
Leandro A. F. Pereira [Thu, 19 Sep 2013 19:05:22 +0000 (12:05 -0700)]
Merge pull request #156 from jeez/js-style-checker
Add a Javascript style checker to our APIs
Ricardo de Almeida Gonzaga [Thu, 19 Sep 2013 17:14:43 +0000 (14:14 -0300)]
[Time] Support timezone optional argument
Ricardo de Almeida Gonzaga [Thu, 19 Sep 2013 16:37:59 +0000 (13:37 -0300)]
[Time] Add TimeDuration getters and setters
TimeDurationObj.foo = null is not accepted
Ricardo de Almeida Gonzaga [Thu, 19 Sep 2013 14:30:57 +0000 (11:30 -0300)]
[Time] equalsTo, lessThan and greaterThan are now throwing exceptions
cmarcelo [Thu, 19 Sep 2013 17:23:17 +0000 (10:23 -0700)]
Merge pull request #157 from cmarcelo/notification-js-api-fixes
Notification js api fixes
Caio Marcelo de Oliveira Filho [Thu, 19 Sep 2013 15:27:51 +0000 (12:27 -0300)]
[Notification] More default values for properties
Jesus Sanchez-Palencia [Thu, 19 Sep 2013 14:53:05 +0000 (11:53 -0300)]
Add a README file.
Caio Marcelo de Oliveira Filho [Thu, 19 Sep 2013 15:05:47 +0000 (12:05 -0300)]
[Notification] Throw when calling constructors without new
Caio Marcelo de Oliveira Filho [Thu, 19 Sep 2013 14:25:30 +0000 (11:25 -0300)]
[Notification] Make removal immediate, add NOT_FOUND_ERR
Jesus Sanchez-Palencia [Thu, 19 Sep 2013 14:27:21 +0000 (11:27 -0300)]
[Bluetooth] Fix bluetooth_api.js according to our style
Caio Marcelo de Oliveira Filho [Wed, 18 Sep 2013 21:48:46 +0000 (18:48 -0300)]
[Notification] Fixes default values of attributes
Caio Marcelo de Oliveira Filho [Wed, 18 Sep 2013 20:45:39 +0000 (17:45 -0300)]
[Notification] Missing passing argument to NotificationCenter.get()
Jesus Sanchez-Palencia [Thu, 19 Sep 2013 14:25:52 +0000 (11:25 -0300)]
Add a JavaScript Lint script that uses Google's Closure Lint.
It will simply run Google's closure Lint, but ignoring
the absence of JSDocs and extending max_line_length to 100 columns.
Kenneth Rohde Christiansen [Thu, 19 Sep 2013 10:35:28 +0000 (03:35 -0700)]
Merge pull request #154 from vcgomes/bluetooth-service-handler
[Bluetooth] Add registerRFCOMMServiceByUUID
Kenneth Rohde Christiansen [Thu, 19 Sep 2013 10:29:46 +0000 (03:29 -0700)]
Merge pull request #153 from vcgomes/bluetooth-fixes
[Bluetooth] Fixes dealing with sync replies and the instance destruction
Kenneth Rohde Christiansen [Thu, 19 Sep 2013 10:27:58 +0000 (03:27 -0700)]
Merge pull request #152 from vcgomes/bluetooth-set-powered-workaround
bluetooth: Add a simple workaround for setPowered()
Vinicius Costa Gomes [Wed, 18 Sep 2013 20:38:51 +0000 (17:38 -0300)]
bluetooth: Add a simple workaround for setPowered()
When the adapter is already powered we may just call the callback.
This is just a temporary solution until there is a proper solution for
the problem of the adapter exiting the USB bus, when it is powered down.
Vinicius Costa Gomes [Fri, 23 Aug 2013 22:23:52 +0000 (19:23 -0300)]
packaging: Link with libbluetooth
Now that we are using functions provided by libbluetooth we need to
link against it.
Vinicius Costa Gomes [Thu, 22 Aug 2013 18:40:49 +0000 (15:40 -0300)]
bluetooth: Add support for notifying that a socket as data available
This adds the SocketHasData message that has as parameters the data
that came from the socket and the socket file descriptor number on
which it came.
Vinicius Costa Gomes [Thu, 22 Aug 2013 19:51:29 +0000 (16:51 -0300)]
bluetooth: Add support for registerRFCOMMServiceByUUID
This will create a service handler (in BlueZ terms, a socket listening on
an RFCOMM channel and a SDP record identifying this service), which has a
callback that will be called when a remote device connects to this service.
Vinicius Costa Gomes [Tue, 20 Aug 2013 22:20:41 +0000 (19:20 -0300)]
bluetooth: Add handler for RFCOMMListen message
This will allow for ServiceHandlers, the server side of RFCOMM, to be
created.
Vinicius Costa Gomes [Thu, 5 Sep 2013 19:07:31 +0000 (16:07 -0300)]
bluetooth: Cancel all pending calls on the destructor
We explicitly leak the GCancellable, because the calls are cancelled
asynchronously and they may survive BluetoothContext. We will only
free them on the shutdown callback of the extension.
Vinicius Costa Gomes [Tue, 3 Sep 2013 23:27:54 +0000 (20:27 -0300)]
bluetooth: Fix replying to getDefaultAdapter() before it is ready
Before we can reply to that message we need to be sure that we have
all the information about the adapter (its path, address, for example)
or that information can't be obtained (BlueZ isn't running).
cmarcelo [Wed, 18 Sep 2013 21:46:40 +0000 (14:46 -0700)]
Merge pull request #151 from cmarcelo/notification-use-v8tools
[Notification] Use forceSetProperty to permit true readonly values
Caio Marcelo de Oliveira Filho [Wed, 18 Sep 2013 21:29:52 +0000 (18:29 -0300)]
[Notification] Use forceSetProperty to permit true readonly values
Kenneth Rohde Christiansen [Wed, 18 Sep 2013 21:03:37 +0000 (14:03 -0700)]
Merge pull request #149 from ricardotk/wip
Fix Time API
cmarcelo [Wed, 18 Sep 2013 20:56:45 +0000 (13:56 -0700)]
Merge pull request #150 from cmarcelo/notification-fixes
Notification fixes
Caio Marcelo de Oliveira Filho [Wed, 18 Sep 2013 20:19:13 +0000 (17:19 -0300)]
[Notification] Fix wrong loop in OnDetailedChanged
The loop was missing incrementing the iterator. This led to an infinite
loop, and then to crash in the extension process. This patch experiments
with std::find_if to avoid having to write the raw loop at all.
Ricardo de Almeida Gonzaga [Wed, 18 Sep 2013 19:58:23 +0000 (16:58 -0300)]
[Time] Correctly calculate the difference and return in DAYS or MSECS
Ricardo de Almeida Gonzaga [Wed, 18 Sep 2013 18:34:06 +0000 (15:34 -0300)]
[Time] Fix toString()
Ricardo de Almeida Gonzaga [Wed, 18 Sep 2013 17:42:26 +0000 (14:42 -0300)]
[Time] Constructor now accepting JSDate as argument
Caio Marcelo de Oliveira Filho [Wed, 18 Sep 2013 17:18:06 +0000 (14:18 -0300)]
[Notification] Remove locking from NotificationManager in mobile
Locking was necessary because each instance was running in a separated
thread, but now all of them share the same thread, so it's safe to
access shared state without locking.
Caio Marcelo de Oliveira Filho [Wed, 18 Sep 2013 17:12:50 +0000 (14:12 -0300)]
[Notification] Fix leaking ContextAPI object
Caio Marcelo de Oliveira Filho [Wed, 18 Sep 2013 17:12:26 +0000 (14:12 -0300)]
[Notification] Make constructor explicit
Jesus Sanchez-Palencia [Wed, 18 Sep 2013 16:34:27 +0000 (09:34 -0700)]
Merge pull request #147 from ricardotk/wip
Fix Time API
Ricardo de Almeida Gonzaga [Wed, 18 Sep 2013 15:22:35 +0000 (12:22 -0300)]
[Time] difference is now throwing exceptions
Ricardo de Almeida Gonzaga [Wed, 18 Sep 2013 14:06:05 +0000 (11:06 -0300)]
[Time] Add _throwProperTizenException()
Kenneth Rohde Christiansen [Wed, 18 Sep 2013 14:06:12 +0000 (07:06 -0700)]
Merge pull request #141 from ricardotk/wip
Time API fixes
Ricardo de Almeida Gonzaga [Tue, 17 Sep 2013 17:00:51 +0000 (14:00 -0300)]
[Time] equalsTo, earlierThan and laterThan now are throwing exceptions
Ricardo de Almeida Gonzaga [Tue, 17 Sep 2013 14:03:45 +0000 (11:03 -0300)]
[Time] Fix TZDate constructor
Some of the arguments are optional
Ricardo de Almeida Gonzaga [Tue, 17 Sep 2013 13:40:11 +0000 (10:40 -0300)]
[Time] Refactor TimeDuration
Some tests needed to access its variables 'length' and 'unit'
Ricardo de Almeida Gonzaga [Tue, 17 Sep 2013 17:03:04 +0000 (14:03 -0300)]
[Time] Fix getDay misunderstanding
getDay() returns the day of the week (0 - 6)
getDate() returns the day of the month (1 - 31)
Ricardo de Almeida Gonzaga [Mon, 16 Sep 2013 19:14:13 +0000 (16:14 -0300)]
[Time] Fix secondsFromUTC() and add getTime()
Ricardo de Almeida Gonzaga [Mon, 16 Sep 2013 19:11:19 +0000 (16:11 -0300)]
[Time] Add missing setFullYear, getSeconds, setSeconds
Kenneth Rohde Christiansen [Wed, 18 Sep 2013 09:14:09 +0000 (02:14 -0700)]
Merge pull request #146 from legendlee1314/upstream_master
[SystemInfo] Fix throwing exception with null callback
Kenneth Rohde Christiansen [Wed, 18 Sep 2013 09:13:36 +0000 (02:13 -0700)]
Merge pull request #139 from legendlee1314/master
[SystemInfo][WIFI-Network] Fix illogical error callback and uniform to use C-API listener
legendlee1314 [Wed, 18 Sep 2013 08:49:41 +0000 (16:49 +0800)]
[SystemInfo] Fix throwing exception with null callback
Kenneth Rohde Christiansen [Wed, 18 Sep 2013 07:36:46 +0000 (00:36 -0700)]
Merge pull request #145 from fyraimar/master
[SystemInfo][CPU] Modify cpu usage calculation algorithm
fyraimar [Thu, 19 Sep 2013 02:55:09 +0000 (10:55 +0800)]
[SystemInfo][CPU] Modify cpu usage calculation algorithm
Kenneth Rohde Christiansen [Wed, 18 Sep 2013 07:33:16 +0000 (00:33 -0700)]
Merge pull request #142 from jeez/bt-fix
[Bluetooth] Remove unused variables
legendlee1314 [Fri, 13 Sep 2013 07:55:01 +0000 (15:55 +0800)]
[SystemInfo][WIFI-Network] Fix illogical error callback and uniform to use C-API listener
Jesus Sanchez-Palencia [Tue, 17 Sep 2013 19:05:04 +0000 (12:05 -0700)]
Merge pull request #143 from darktears/power-fixes
Power fixes
Alexis Menard [Tue, 17 Sep 2013 18:39:49 +0000 (15:39 -0300)]
[Power] Make test PowerManager_setScreenBrightness_brightness_TypeMismatch pass.
We need to throw the right error when the brightness passed is -Infinite,
+Infinite or NaN.
Alexis Menard [Tue, 17 Sep 2013 18:21:50 +0000 (15:21 -0300)]
[Power] Fix Power API failures on tct test suites.
-Remove workaround of glib callback as it is not needed anymore : the
extensions run in a separate process.
-Remove commented code in the examples as now switching on and off doesn't
background crosswalk behind the launcher.
Jesus Sanchez-Palencia [Tue, 17 Sep 2013 17:53:41 +0000 (14:53 -0300)]
[Bluetooth] Remove unused variables
Kenneth Rohde Christiansen [Tue, 17 Sep 2013 10:51:57 +0000 (03:51 -0700)]
Merge pull request #140 from legendlee1314/new_master
[SystemInfo][Network] Add WIFI network-type and uniform to use C-API listener
legendlee1314 [Tue, 17 Sep 2013 07:42:11 +0000 (15:42 +0800)]
[SystemInfo][Network] Add WIFI network-type and uniform to use C-API listener
Kenneth Rohde Christiansen [Mon, 16 Sep 2013 22:42:33 +0000 (15:42 -0700)]
Merge pull request #137 from cmarcelo/example-menu-flex
Make examples index.html easier to click now with flex
Caio Marcelo de Oliveira Filho [Mon, 16 Sep 2013 22:04:53 +0000 (19:04 -0300)]
Make examples index.html easier to click now with flex
Kenneth Rohde Christiansen [Mon, 16 Sep 2013 22:23:10 +0000 (15:23 -0700)]
Merge pull request #136 from cmarcelo/example-menu
Make examples index.html easier to click
Caio Marcelo de Oliveira Filho [Mon, 16 Sep 2013 22:04:53 +0000 (19:04 -0300)]
Make examples index.html easier to click
Kenneth Rohde Christiansen [Mon, 16 Sep 2013 11:00:11 +0000 (04:00 -0700)]
Merge pull request #135 from halton/master
[SystemInfo] Fix style checking error caused by PR #132
Halton Huo [Mon, 16 Sep 2013 10:54:39 +0000 (18:54 +0800)]
[SystemInfo] Fix style checking error caused by PR #132
Kenneth Rohde Christiansen [Mon, 16 Sep 2013 09:22:52 +0000 (02:22 -0700)]
Merge pull request #132 from Ryan--Yang/master
[SystemInfo]fix error when value changed of the battery
yangruiintel [Mon, 16 Sep 2013 08:49:10 +0000 (16:49 +0800)]
[SystemInfo]fix error when value changed of the battery
Kenneth Rohde Christiansen [Mon, 16 Sep 2013 07:58:05 +0000 (00:58 -0700)]
Merge pull request #130 from halton/master
Allow run tools/check-coding-style from any place
Halton Huo [Mon, 16 Sep 2013 03:36:57 +0000 (11:36 +0800)]
Allow run tools/check-coding-style from any place