root/apps/iphone/superbook/trunk/Classes/FriendsMapViewController.h
@
363
| Revision 363, 3.4 kB (checked in by henri, 4 years ago) |
|---|
| Line | |
|---|---|
| 1 | // |
| 2 | // FriendsMapViewController.h |
| 3 | // LocateThem |
| 4 | // |
| 5 | // Created by Henri Asseily on 8/26/08. |
| 6 | /* |
| 7 | Copyright (c) 2008-2009, Telnic Ltd. All rights reserved. |
| 8 | |
| 9 | Redistribution and use in source and binary forms, with or without modification, |
| 10 | are permitted provided that the following conditions are met: |
| 11 | |
| 12 | Redistributions of source code must retain the above copyright notice, this list of conditions |
| 13 | and the following disclaimer. Redistributions in binary form must reproduce the above copyright |
| 14 | notice, this list of conditions and the following disclaimer in the documentation and/or other |
| 15 | materials provided with the distribution. |
| 16 | Neither the name of the Telnic Ltd. nor the names of its contributors may be used to endorse or |
| 17 | promote products derived from this software without specific prior written permission. |
| 18 | THIS DOCUMENTATION IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS |
| 19 | OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY |
| 20 | AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR |
| 21 | CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
| 22 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
| 23 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER |
| 24 | IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY |
| 25 | OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 26 | */ |
| 27 | // |
| 28 | // Singleton class to display the map |
| 29 | |
| 30 | #import <UIKit/UIKit.h> |
| 31 | #import "MapView/RMMapView.h" |
| 32 | #import "MapView/RMMarker.h" |
| 33 | #import "MapView/RMMarkerManager.h" |
| 34 | #import "MapView/RMOpenStreetMapsSource.h" |
| 35 | #import "MapView/RMVirtualEarthSource.h" |
| 36 | #import "MapView/RMCloudMadeMapSource.h" |
| 37 | #import <CoreLocation/CoreLocation.h> |
| 38 | #import "MyCLController.h" |
| 39 | |
| 40 | @interface FriendsMapViewController : UIViewController <RMMapViewDelegate, MyCLControllerDelegate, UIActionSheetDelegate>{ |
| 41 | IBOutlet UILabel *labelGpsLastUpdateDate; |
| 42 | IBOutlet UIToolbar *actionBar; |
| 43 | IBOutlet UIBarButtonItem *buttonMoveTo; |
| 44 | IBOutlet RMMapView *theMap; |
| 45 | CLLocation *initialLoc; |
| 46 | UIImage *markerGpsImage; |
| 47 | UIImage *markerRedImage; |
| 48 | UIImage *markerBlueImage; |
| 49 | RMMarker *markerGps; |
| 50 | @private |
| 51 | BOOL gpsLocIsAvailable; |
| 52 | NSInteger moveToGPSButtonIndex; |
| 53 | NSMutableDictionary *uniqueMarkers; |
| 54 | NSMutableArray *firstMarkers; // marker list before view is created, so view can be loaded lazily |
| 55 | } |
| 56 | |
| 57 | + (FriendsMapViewController *)sharedInstance; |
| 58 | |
| 59 | - (void) setMarkers:(NSDictionary *)peopleList; |
| 60 | - (void) setMarkerWithABRecordId:(NSNumber *)theId |
| 61 | title:(NSString *)title |
| 62 | telname:(NSString *)telname |
| 63 | location:(CLLocation *)loc; |
| 64 | |
| 65 | - (IBAction)didPressCenterGps:(id)sender; |
| 66 | - (IBAction)didPressMoveTo:(id)sender; |
| 67 | - (IBAction)gpsSwitchToggled:(UISwitch *)sender; |
| 68 | |
| 69 | @property (nonatomic, retain) IBOutlet UILabel *labelGpsLastUpdateDate; |
| 70 | @property (nonatomic, retain) IBOutlet UIToolbar *actionBar; |
| 71 | @property (nonatomic, retain) IBOutlet UIBarButtonItem *buttonMoveTo; |
| 72 | @property (nonatomic, retain) IBOutlet RMMapView *theMap; |
| 73 | @property (nonatomic, copy) CLLocation *initialLoc; |
| 74 | @property (nonatomic, retain) UIImage *markerGpsImage; |
| 75 | @property (nonatomic, retain) UIImage *markerRedImage; |
| 76 | @property (nonatomic, retain) UIImage *markerBlueImage; |
| 77 | @property (nonatomic, retain) RMMarker *markerGps; |
| 78 | |
| 79 | @end |
Note: See TracBrowser
for help on using the browser.








