Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
tastyone committed May 3, 2012
1 parent af0e8d9 commit 6a1b356
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,21 @@ MotionOrientation
An observer to notify the orientation of iOS device changed, using CoreMotion for taking the orientation in 'Orientation Lock'.

Usage
<code>
=====

Run below.

<pre>
[MotionOrientation initialize];
/* ... */
</code>
</pre>

You can receive notifications below.
Then you can receive notifications below.

MotionOrientationChangedNotification when the device orientation changed.
MotionOrientationInterfaceOrientationChangedNotification when the interface orientation changed.
<strong>MotionOrientationChangedNotification</strong>, when the device orientation changed.
<strong>MotionOrientationInterfaceOrientationChangedNotification</strong>, just when the interface orientation changed.

And then you can retrieve orientation informations.
<pre>
UIInterfaceOrientation interfaceOrientation = [MotionOrientation sharedInstance].interfaceOrientation;
UIDeviceOrientation deviceOrientation = [MotionOrientation sharedInstance].deviceOrientation;
</pre>

0 comments on commit 6a1b356

Please sign in to comment.