Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test1.7 #40

Open
wants to merge 40 commits into
base: 1.7
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
70d026e
first
PrevaultNoel Jan 21, 2015
4378f9e
Création page
PrevaultNoel Jan 21, 2015
468cb61
Création contrôler webview
PrevaultNoel Jan 21, 2015
43fdfd2
Remote
PrevaultNoel Jan 21, 2015
b854dac
Creation ViewActuController
PrevaultNoel Jan 21, 2015
b39febd
Remise fonctionnelle problème de conception webview
PrevaultNoel Jan 21, 2015
5c20759
Modification page test webview
PrevaultNoel Jan 21, 2015
d08cfc6
Complétion script webview twitter
PrevaultNoel Jan 22, 2015
c584d8f
Test bouton vers page Twitter
PrevaultNoel Jan 22, 2015
09c312f
Page Twitter Fonctionnelle
PrevaultNoel Jan 22, 2015
71e09aa
Ajout bouton Twitter
PrevaultNoel Jan 28, 2015
d8e3477
Correction bouton Twitter
PrevaultNoel Jan 28, 2015
202f11f
Changement design
PrevaultNoel Feb 5, 2015
d002bf5
Remise bouton retour
PrevaultNoel Feb 5, 2015
e230174
Modifications de pages
PrevaultNoel Feb 5, 2015
d1cd2eb
Problème avec introduction
PrevaultNoel Feb 5, 2015
802db4b
Premiers tests pour changement design
PrevaultNoel Feb 8, 2015
6fb082e
Corrections graphiques
PrevaultNoel Feb 8, 2015
085d096
Deuxième corrections graphiques
PrevaultNoel Feb 8, 2015
7fe5dbb
Test graphique news
PrevaultNoel Feb 8, 2015
af8b7bb
Seconds tests graphiques news
PrevaultNoel Feb 8, 2015
fba1c5b
Correction du script machine à gaz de Facebook
PrevaultNoel Feb 14, 2015
50491cf
Mise en fonction du nouveau script Facebook optimisé
PrevaultNoel Feb 14, 2015
b3071dc
Correctifs
PrevaultNoel Feb 22, 2015
3104e32
Correctifs
PrevaultNoel Feb 22, 2015
2710737
Ajout nouvelles pages
PrevaultNoel Feb 22, 2015
7b6cd82
Ajout Controller de selection étage pour plan
PrevaultNoel Feb 22, 2015
a007453
Ajout pages plan 1, 2 et 3
PrevaultNoel Feb 22, 2015
2deb771
Ajouts fonctionnalités
PrevaultNoel Feb 22, 2015
70be027
Suppression page pour cause de problèmes
PrevaultNoel Feb 22, 2015
2813899
Changements et correctifs
PrevaultNoel Feb 22, 2015
76b2ff2
Ajout et finalisation page plan avec scrollview
PrevaultNoel Mar 1, 2015
df8fe43
Corrections finales version
PrevaultNoel Mar 2, 2015
866890c
Build
PrevaultNoel Mar 2, 2015
01fe6f4
Rajout
PrevaultNoel Mar 3, 2015
d63ef3e
Rajout actuTwitter
PrevaultNoel Mar 3, 2015
e82dbc0
Corrections
PrevaultNoel Mar 3, 2015
934ca3e
Corrections différents header, premières corrections boutons et place…
PrevaultNoel Mar 4, 2015
6c0d99f
Corrections diverses
PrevaultNoel Mar 4, 2015
225a152
Finalisation placement header et zones
PrevaultNoel Mar 5, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified .DS_Store
Binary file not shown.
Binary file modified 114x114.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified 120x120.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified 29x29.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified 57x57.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified 58x58.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified 80x80.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
60 changes: 50 additions & 10 deletions AppliIUTSDdeLorraine.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?xml version="1.0" encoding="UTF-8"?>
<Bucket
type = "1"
version = "2.0">
<Breakpoints>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AppliIUTSDdeLorraine/ActuViewController.m"
timestampString = "443629395.324139"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "15"
endingLineNumber = "15"
landmarkName = "@implementation ActuViewController"
landmarkType = "3">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AppliIUTSDdeLorraine/WebViewController.m"
timestampString = "445624260.643032"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "15"
endingLineNumber = "15"
landmarkName = "webView"
landmarkType = "19">
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>
Binary file modified AppliIUTSDdeLorraine/.DS_Store
Binary file not shown.
Binary file added AppliIUTSDdeLorraine/0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added AppliIUTSDdeLorraine/1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added AppliIUTSDdeLorraine/2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
15 changes: 15 additions & 0 deletions AppliIUTSDdeLorraine/ActuController.pch
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
//
// ActuController.pch
// AppliIUTSDdeLorraine
//
// Created by Noël Prévault on 21/01/2015.
// Copyright (c) 2015 Damien Bannerot. All rights reserved.
//

#ifndef AppliIUTSDdeLorraine_ActuController_pch
#define AppliIUTSDdeLorraine_ActuController_pch

// Include any system framework and library headers here that should be included in all compilation units.
// You will also need to set the Prefix Header build setting of one or more of your targets to reference this file.

#endif
16 changes: 16 additions & 0 deletions AppliIUTSDdeLorraine/ActuTwitter.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="style.css" media="screen" />
</head>

<body>

<a class='twitter-timeline' data-dnt='true' href='https://twitter.com/AppIUTSD/lists/application-iutsd' data-widget-id='556870866601246721'>Tweets de https://twitter.com/AppIUTSD/lists/application-iutsd</a>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+'://platform.twitter.com/widgets.js';fjs.parentNode.insertBefore(js,fjs);}}(document,'script','twitter-wjs');</script>



</body>
</html>

36 changes: 36 additions & 0 deletions AppliIUTSDdeLorraine/ActuViewController.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
//
// ActuViewController.h
// AppliIUTSDdeLorraine
//
// Created by Noël Prévault on 21/01/2015.
// Copyright (c) 2015 Damien Bannerot. All rights reserved.
//

#import <UIKit/UIKit.h>


@interface ActuViewController : UIViewController<UIWebViewDelegate>{

IBOutlet UIWebView *Actu;
}

@property (nonatomic, retain) IBOutlet UIWebView *Actu;

- (IBAction)done:(id)sender;
@end
















40 changes: 40 additions & 0 deletions AppliIUTSDdeLorraine/ActuViewController.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
//
// ActuViewController.m
// AppliIUTSDdeLorraine
//
// Created by Noël Prévault on 21/01/2015.
// Copyright (c) 2015 Damien Bannerot. All rights reserved.
//

#import "ActuViewController.h"

@interface ActuViewController ()

@end

@implementation ActuViewController

@synthesize Actu;

- (IBAction)done:(id)sender {
[self dismissViewControllerAnimated:YES completion:nil];
}
- (void)viewDidLoad
{
[super viewDidLoad];
NSURL * resourcePathURL = [[NSBundle mainBundle] resourceURL];
if(resourcePathURL)
{
NSURL * urlToLoad = [resourcePathURL
URLByAppendingPathComponent: @"ActuTwitter.html"];
if(urlToLoad)
{
NSURLRequest * req = [NSURLRequest requestWithURL: urlToLoad];
[Actu loadRequest: req];
}
}
}
- (BOOL )shouldAutorotate{
return NO;
}
@end
13 changes: 13 additions & 0 deletions AppliIUTSDdeLorraine/ActuWebView.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
//
// ActuWebView.h
// AppliIUTSDdeLorraine
//
// Created by Noël Prévault on 21/01/2015.
// Copyright (c) 2015 Damien Bannerot. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface ActuWebView : NSObject

@end
13 changes: 13 additions & 0 deletions AppliIUTSDdeLorraine/ActuWebView.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
//
// ActuWebView.m
// AppliIUTSDdeLorraine
//
// Created by Noël Prévault on 21/01/2015.
// Copyright (c) 2015 Damien Bannerot. All rights reserved.
//

#import "ActuWebView.h"

@implementation ActuWebView

@end
2 changes: 2 additions & 0 deletions AppliIUTSDdeLorraine/AppDelegate.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@
@property (strong, nonatomic) UIWindow *window;

@end


4 changes: 2 additions & 2 deletions AppliIUTSDdeLorraine/AppliIUTSDdeLorraine-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.6</string>
<string>1.8</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.6.9</string>
<string>1.8</string>
<key>LSApplicationCategoryType</key>
<string></string>
<key>LSRequiresIPhoneOS</key>
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified AppliIUTSDdeLorraine/Images.xcassets/AppIcon.appiconset/80x80.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 27 additions & 0 deletions AppliIUTSDdeLorraine/PlanController.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
//
// PlanController.h
// AppliIUTSDdeLorraine
//
// Created by Noël Prévault on 26/02/2015.
// Copyright (c) 2015 Damien Bannerot. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "SlidableView.h"

@interface PlanController : UIViewController<UIScrollViewDelegate>{
IBOutlet UIView *viewAnimates;
IBOutlet UIImageView *topImage;
IBOutlet UIButton *myButtonBack;

}


@property (nonatomic, strong) IBOutlet UIScrollView *scrollView;
@property (nonatomic, retain) IBOutlet UIImageView *topImage;
@property (nonatomic, retain) IBOutlet UIButton *myButtonBack;

- (IBAction)back:(id)sender;


@end
139 changes: 139 additions & 0 deletions AppliIUTSDdeLorraine/PlanController.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
//
// PlanController.m
// AppliIUTSDdeLorraine
//
// Created by Noël Prévault on 26/02/2015.
// Copyright (c) 2015 Damien Bannerot. All rights reserved.
//

#import "PlanController.h"
#import "Utils.h"

@interface PlanController ()
@property (nonatomic, strong) UIImageView *imageView;

- (void)centerScrollViewContents;
- (void)scrollViewDoubleTapped:(UITapGestureRecognizer*)recognizer;
- (void)scrollViewTwoFingerTapped:(UITapGestureRecognizer*)recognizer;

@end

@implementation PlanController

@synthesize topImage, myButtonBack;
@synthesize scrollView = _scrollView;
@synthesize imageView = _imageView;

- (void)centerScrollViewContents {
CGSize boundsSize = self.scrollView.bounds.size;
CGRect contentsFrame = self.imageView.frame;

if (contentsFrame.size.width < boundsSize.width) {
contentsFrame.origin.x = (boundsSize.width - contentsFrame.size.width) / 2.0f;
} else {
contentsFrame.origin.x = 0.0f;
}

if (contentsFrame.size.height < boundsSize.height) {
contentsFrame.origin.y = (boundsSize.height - contentsFrame.size.height) / 2.0f;
} else {
contentsFrame.origin.y = 0.0f;
}

self.imageView.frame = contentsFrame;
}

- (void)scrollViewDoubleTapped:(UITapGestureRecognizer*)recognizer {
CGPoint pointInView = [recognizer locationInView:self.imageView];

CGFloat newZoomScale = self.scrollView.zoomScale * 1.5f;
newZoomScale = MIN(newZoomScale, self.scrollView.maximumZoomScale);

CGSize scrollViewSize = self.scrollView.bounds.size;

CGFloat w = scrollViewSize.width / newZoomScale;
CGFloat h = scrollViewSize.height / newZoomScale;
CGFloat x = pointInView.x - (w / 2.0f);
CGFloat y = pointInView.y - (h / 2.0f);

CGRect rectToZoomTo = CGRectMake(x, y, w, h);

[self.scrollView zoomToRect:rectToZoomTo animated:YES];
}

- (void)scrollViewTwoFingerTapped:(UITapGestureRecognizer*)recognizer {
CGFloat newZoomScale = self.scrollView.zoomScale / 1.5f;
newZoomScale = MAX(newZoomScale, self.scrollView.minimumZoomScale);
[self.scrollView setZoomScale:newZoomScale animated:YES];
}

- (void)viewDidLoad {
[super viewDidLoad];
UIImage *image = [UIImage imageNamed:@"carte.jpg"];
self.imageView = [[UIImageView alloc] initWithImage:image];
self.imageView.frame = (CGRect){.origin=CGPointMake(0.0f, 0.0f), .size=image.size};
[self.scrollView addSubview:self.imageView];

self.scrollView.contentSize = image.size;

UITapGestureRecognizer *doubleTapRecognizer = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(scrollViewDoubleTapped:)];
doubleTapRecognizer.numberOfTapsRequired = 2;
doubleTapRecognizer.numberOfTouchesRequired = 1;
[self.scrollView addGestureRecognizer:doubleTapRecognizer];

UITapGestureRecognizer *twoFingerTapRecognizer = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(scrollViewTwoFingerTapped:)];
twoFingerTapRecognizer.numberOfTapsRequired = 1;
twoFingerTapRecognizer.numberOfTouchesRequired = 2;
[self.scrollView addGestureRecognizer:twoFingerTapRecognizer];
}

- (void)viewWillAppear:(BOOL)animated {
[super viewWillAppear:animated];

CGRect scrollViewFrame = self.scrollView.frame;
CGFloat scaleWidth = scrollViewFrame.size.width / self.scrollView.contentSize.width;
CGFloat scaleHeight = scrollViewFrame.size.height / self.scrollView.contentSize.height;
CGFloat minScale = MIN(scaleWidth, scaleHeight);

self.scrollView.minimumZoomScale = minScale;
self.scrollView.maximumZoomScale = 1.0f;
self.scrollView.zoomScale = minScale;

[self centerScrollViewContents];
}

- (void)viewDidUnload
{
[super viewDidUnload];
}

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown);
}

- (UIView*)viewForZoomingInScrollView:(UIScrollView *)scrollView {
return self.imageView;
}

- (void)scrollViewDidZoom:(UIScrollView *)scrollView {
[self centerScrollViewContents];
}

- (IBAction)back:(id)sender {
[myButtonBack setEnabled:NO];
[self dismissViewControllerAnimated:YES completion:nil];
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
// Get the new view controller using [segue destinationViewController].
// Pass the selected object to the new view controller.
}
*/
@end


Loading