You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by mw...@apache.org on 2012/05/08 00:25:12 UTC
[5/5] docs commit: Remove unused spec for QuirksMerger.
Remove unused spec for QuirksMerger.
Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/commit/c4edc996
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/tree/c4edc996
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/diff/c4edc996
Branch: refs/heads/master
Commit: c4edc996baf645b4129a686dd94a3695e9f4c5dd
Parents: ec76a99
Author: Michael Brooks <mi...@michaelbrooks.ca>
Authored: Mon May 7 15:21:29 2012 -0700
Committer: Michael Brooks <mi...@michaelbrooks.ca>
Committed: Mon May 7 15:21:29 2012 -0700
----------------------------------------------------------------------
spec/phonegap/quirks_merger_spec.rb | 51 ------
.../android/accelerometer/watch_acceleration.md | 21 ---
.../android/droid/text_to_speech.md | 28 ----
.../expected/watch_acceleration.md | 118 ---------------
.../phonegap/accelerometer/watch_acceleration.md | 113 --------------
5 files changed, 0 insertions(+), 331 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/blob/c4edc996/spec/phonegap/quirks_merger_spec.rb
----------------------------------------------------------------------
diff --git a/spec/phonegap/quirks_merger_spec.rb b/spec/phonegap/quirks_merger_spec.rb
deleted file mode 100644
index ea83d4e..0000000
--- a/spec/phonegap/quirks_merger_spec.rb
+++ /dev/null
@@ -1,51 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-$:.unshift File.join(File.dirname(__FILE__), '..')
-require 'spec_helpers'
-require 'quirks_merger'
-
-describe QuirksMerger do
- before :all do
- @directory = Helper::create_tmp_directory_assets(__FILE__)
- @merger = QuirksMerger.new
- end
-
- it 'should not merge platform-only files' do
- filename = File.join(@directory, 'android', 'droid', 'text_to_speech.md')
- @merger.run filename
-
- File.exists?(filename).should be_true
- end
-
- it 'should merge phonegap-core files' do
- filename = File.join(@directory, 'android', 'accelerometer', 'watch_acceleration.md')
-
- # Merge the file
- @merger.run filename
- File.exists?(filename).should be_false
-
- # Verify that it is a concatination
- cat_data = File.read( File.join @directory, 'phonegap', 'accelerometer', 'watch_acceleration.md' )
- expected_data = File.read( File.join @directory, 'expected', 'watch_acceleration.md' )
- cat_data.should == expected_data
- end
-
- after :all do
- Helper::remove_tmp_directory
- end
-end
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/blob/c4edc996/spec/phonegap/quirks_merger_spec/android/accelerometer/watch_acceleration.md
----------------------------------------------------------------------
diff --git a/spec/phonegap/quirks_merger_spec/android/accelerometer/watch_acceleration.md b/spec/phonegap/quirks_merger_spec/android/accelerometer/watch_acceleration.md
deleted file mode 100644
index cd8bfab..0000000
--- a/spec/phonegap/quirks_merger_spec/android/accelerometer/watch_acceleration.md
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-Android Quirks:
----------------
-
-Watch acceleration is a little wonky right now.
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/blob/c4edc996/spec/phonegap/quirks_merger_spec/android/droid/text_to_speech.md
----------------------------------------------------------------------
diff --git a/spec/phonegap/quirks_merger_spec/android/droid/text_to_speech.md b/spec/phonegap/quirks_merger_spec/android/droid/text_to_speech.md
deleted file mode 100644
index 1fbf601..0000000
--- a/spec/phonegap/quirks_merger_spec/android/droid/text_to_speech.md
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-Text to Speech
-==============
-
-> Incredibly cool function that performs text-to-speech on the `String` parameter.
-
- phonegap.droid.textToSpeech(string);
-
-Parameters
-----------
-
-- string (`String`) Whatever you want your little robot to say.
http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/blob/c4edc996/spec/phonegap/quirks_merger_spec/expected/watch_acceleration.md
----------------------------------------------------------------------
diff --git a/spec/phonegap/quirks_merger_spec/expected/watch_acceleration.md b/spec/phonegap/quirks_merger_spec/expected/watch_acceleration.md
deleted file mode 100644
index 0574aa9..0000000
--- a/spec/phonegap/quirks_merger_spec/expected/watch_acceleration.md
+++ /dev/null
@@ -1,118 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-Accelerometer Watch Acceleration
-================================
-
-At a regular interval, get the acceleration along the x, y, and z axis.
-
- var watchID = navigator.accelerometer.watchAcceleration(onSuccess, onError, [options]);
-
-Description
------------
-
-The accelerometer is a motion sensor that detects the change (delta) in movement relative to the current position. The accelerometer can detect 3D movement along the x, y, and z axis.
-
-Quick Example
--------------
-
- function(acceleration) {
- alert('Acceleration X: ' + acceleration.x + '\n' +
- 'Acceleration Y: ' + acceleration.y + '\n' +
- 'Acceleration Z: ' + acceleration.z + '\n';
- };
-
- function onError() {
- alert('onError!');
- };
-
- var options = { frequency: 3000 }; // Update every 3 seconds
-
- var watchID = navigator.accelerometer.watchAcceleration(onSuccess, onError, options);
-
-Full Example
-------------
-
- <!DOCTYPE html>
- <html>
- <head>
- <title>Acceleration Example</title>
-
- <script type="text/javascript" charset="utf-8" src="phonegap.js"></script>
- <script type="text/javascript" charset="utf-8">
-
- // The watch id references the current `watchAcceleration`
- var watchID = null;
-
- // Wait for PhoneGap to load
- //
- function onLoad() {
- document.addEventListener("deviceready", onDeviceReady, false);
- }
-
- // PhoneGap is ready
- //
- function onDeviceReady() {
- startWatch();
- }
-
- // Start watching the acceleration
- //
- function startWatch() {
- clearWatch();
-
- // Update acceleration every 3 seconds
- var options = { frequency: 30000 };
-
- watchID = navigator.accelerometer.watchAcceleration(onSuccess, onError, options);
- }
-
- // Stop watching the acceleration
- //
- function stopWatch() {
- if (watchID) {
- navigator.accelerometer.clearWatch(watchID);
- watchID = null;
- }
- }
-
- // onSuccess: Get a snapshot of the current acceleration
- //
- function onSuccess() {
- var element = document.getElementById('accelerometer');
- element.innerHTML = 'Acceleration X: ' + acceleration.x + '<br />' +
- 'Acceleration Y: ' + acceleration.y + '<br />' +
- 'Acceleration Z: ' + acceleration.z + '<br />';
- }
-
- // onError: Failed to get the acceleration
- //
- function onError() {
- alert('onError!');
- }
-
- </script>
- </head>
- <body>
- <div id="accelerometer">Waiting for accelerometer...</div>
- </body>
- </html>
-
-Android Quirks:
----------------
-
-Watch acceleration is a little wonky right now.
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/blob/c4edc996/spec/phonegap/quirks_merger_spec/phonegap/accelerometer/accelerometer.md
----------------------------------------------------------------------
diff --git a/spec/phonegap/quirks_merger_spec/phonegap/accelerometer/accelerometer.md b/spec/phonegap/quirks_merger_spec/phonegap/accelerometer/accelerometer.md
deleted file mode 100644
index e69de29..0000000
http://git-wip-us.apache.org/repos/asf/incubator-cordova-docs/blob/c4edc996/spec/phonegap/quirks_merger_spec/phonegap/accelerometer/watch_acceleration.md
----------------------------------------------------------------------
diff --git a/spec/phonegap/quirks_merger_spec/phonegap/accelerometer/watch_acceleration.md b/spec/phonegap/quirks_merger_spec/phonegap/accelerometer/watch_acceleration.md
deleted file mode 100644
index ea0ba03..0000000
--- a/spec/phonegap/quirks_merger_spec/phonegap/accelerometer/watch_acceleration.md
+++ /dev/null
@@ -1,113 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-Accelerometer Watch Acceleration
-================================
-
-At a regular interval, get the acceleration along the x, y, and z axis.
-
- var watchID = navigator.accelerometer.watchAcceleration(onSuccess, onError, [options]);
-
-Description
------------
-
-The accelerometer is a motion sensor that detects the change (delta) in movement relative to the current position. The accelerometer can detect 3D movement along the x, y, and z axis.
-
-Quick Example
--------------
-
- function(acceleration) {
- alert('Acceleration X: ' + acceleration.x + '\n' +
- 'Acceleration Y: ' + acceleration.y + '\n' +
- 'Acceleration Z: ' + acceleration.z + '\n';
- };
-
- function onError() {
- alert('onError!');
- };
-
- var options = { frequency: 3000 }; // Update every 3 seconds
-
- var watchID = navigator.accelerometer.watchAcceleration(onSuccess, onError, options);
-
-Full Example
-------------
-
- <!DOCTYPE html>
- <html>
- <head>
- <title>Acceleration Example</title>
-
- <script type="text/javascript" charset="utf-8" src="phonegap.js"></script>
- <script type="text/javascript" charset="utf-8">
-
- // The watch id references the current `watchAcceleration`
- var watchID = null;
-
- // Wait for PhoneGap to load
- //
- function onLoad() {
- document.addEventListener("deviceready", onDeviceReady, false);
- }
-
- // PhoneGap is ready
- //
- function onDeviceReady() {
- startWatch();
- }
-
- // Start watching the acceleration
- //
- function startWatch() {
- clearWatch();
-
- // Update acceleration every 3 seconds
- var options = { frequency: 30000 };
-
- watchID = navigator.accelerometer.watchAcceleration(onSuccess, onError, options);
- }
-
- // Stop watching the acceleration
- //
- function stopWatch() {
- if (watchID) {
- navigator.accelerometer.clearWatch(watchID);
- watchID = null;
- }
- }
-
- // onSuccess: Get a snapshot of the current acceleration
- //
- function onSuccess() {
- var element = document.getElementById('accelerometer');
- element.innerHTML = 'Acceleration X: ' + acceleration.x + '<br />' +
- 'Acceleration Y: ' + acceleration.y + '<br />' +
- 'Acceleration Z: ' + acceleration.z + '<br />';
- }
-
- // onError: Failed to get the acceleration
- //
- function onError() {
- alert('onError!');
- }
-
- </script>
- </head>
- <body>
- <div id="accelerometer">Waiting for accelerometer...</div>
- </body>
- </html>
\ No newline at end of file