Giter Site home page Giter Site logo

auk's People

Contributors

dglancy avatar evgenyneu avatar eyaldar avatar valpertui avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

auk's Issues

predownload images?

hi i dont know if this lib could predownload remote images...mean, while user see the first image, other images in scrollview,download concurrently to speed up showing the images

is there any option for that?

Using different download manager

Hello,

Would you consider decoupling Auk from moa and allow for using different image download library, like SDWebImage or AlamofireImage?

I made a switch to SDWebImage myself, only because it is used by another library and they can share the cache this way. Besides, no need to use multiple libraries in the same app that do the same thing.

I could make a PU with what I have if you like.

Thanks.

Page control is not visible

Hi,
page control is not visible if I'm setting images in viewDidLoad method:

`
@IBOutlet weak var carouselView: UIScrollView!
override func viewDidLoad() {
super.viewDidLoad()

    title = NSLocalizedString("PHOTO BOOK INFO", comment: "")
    navigationItem.rightBarButtonItem = nextButtonItem
    edgesForExtendedLayout = UIRectEdge.None

    infoLabel.text = viewModel.templateInfoText
    deliveryLabel.text = viewModel.deliveryText

    carouselView.auk.show(image: UIImage(named: "InfoScreenBook")!)
    carouselView.auk.show(image: UIImage(named: "InfoScreenBook")!)
    carouselView.auk.show(image: UIImage(named: "InfoScreenBook")!)
}

`

Changing Podfile doesn't update the code for Swift 3; keep getting error in Xcode

I'm migrating my dev environment to Xcode 8 and Swift 3. According to Xcode, the Auk and moa code aren't updated to Swift 3 and it keeps asking me to "upgrade the source". I followed the new instructions, deleted all the podfile.lock, the pod folder and also the .xcworkspace file and generated everything again from the terminal; still no luck.

Am I doing something wrong or missing something??

Thank you

Update image on existing page

Is there a way to update the currently displayed image on a certain page?
I've seen in the code that you can change the image using the AukPage's code itself but it seems that there is no way to access the pages or fetch one particular page after it's been added easily.

Am I missing something?

Preloading images

Hi,

I want to use your plugin in a new iOS App and I was wondering if there's any way of preloading the images before you change from one page to the other. I don't seem to find any option either in Auk or Moa. Is that posiible?

Thank you!

Crash App

Hello @evgenyneu

When I run the app with the iPhone 4s and iPhone 5 gives this error :

"(extension in Auk):__ObjC.UIScrollView.auk.getter : Auk.Auk", referenced from:
      balen.MainViewController.(currentImageDescription in _6D33176B14C9C200DCC5C77F42099FC9).getter : Swift.String? in MainViewController.o
      balen.MainViewController.implementation () -> () in MainViewController.o
      balen.MainViewController.imageshow () -> () in MainViewController.o
      balen.MainViewController.viewWillTransitionToSize (__C.CGSize, withTransitionCoordinator : __ObjC.UIViewControllerTransitionCoordinator) -> () in MainViewController.o
      balen.MainViewController.willRotateToInterfaceOrientation (__C.UIInterfaceOrientation, duration : Swift.Double) -> () in MainViewController.o
      balen.MainViewController.(viewWillTransitionToSize (__C.CGSize, withTransitionCoordinator : __ObjC.UIViewControllerTransitionCoordinator) -> ()).(closure #1) in MainViewController.o`

and

type metadata accessor for Auk.Auk", referenced from:
      balen.MainViewController.implementation () -> () in MainViewController.o

Because you know it?

Just a little Typo..

In your README.md file under the section Respond to User Tap you write:

In the Storyboard drag a Tag Gesture Recognizer into your scroll view.

I think you mean "Tap"

Set show url not display image

i try loop add show url in viewdidload but it don't appear, It just show placeholder image.
Can u help me for this one.

Image Size Issue

Hi,

I am having an issue where the imageView in the scrollView is smaller than it should be. I created a test image to test it and the test image ends up being bigger then the scroll view's image. I need the image in the scroll view to be like the test image. The scrollView and the testImage's sizes are the same.

Here is my code:

scrollViewSlider.auk.settings.contentMode = UIViewContentMode.ScaleAspectFit
testImage.contentMode = UIViewContentMode.ScaleAspectFit
scrollViewSlider.auk.show(image: screenShot)
testImage.image = screenShot

Here is the result:

simulator screen shot may 23 2016 2 56 14 pm

Thanks!

How to add image descriptions in slideshow?

Hi,
How can I add image descriptions in slideshow?
Can you add the implementation on README?
I know, you have it already on your Demo, but I want to drag a Strings from Parse server to display them as Image Descriptions in my slideshow, and on your Demo is only for local.

How to enable page indicator?

What I need to do to enable the page indicator? I cloud not find any reference about it in your demo app.

    override func viewDidLoad() {
        scrollView.auk.settings.showsHorizontalScrollIndicator = true
        scrollView.auk.settings.pageControl.visible = true
        scrollView.auk.settings.contentMode = UIViewContentMode.ScaleAspectFill

        let image1 = UIImage(named: "banner_top.jpg")
        self.scrollView.auk.show(image: image1!, accessibilityLabel: "Top")

        let image2 = UIImage(named: "banner_conteudo.jpg")
        self.scrollView.auk.show(image: image2!, accessibilityLabel: "Conteúdo")

        let image3 = UIImage(named: "banner_eventos.jpg")
        self.scrollView.auk.show(image: image3!, accessibilityLabel: "Eventos")

        scrollView.auk.startAutoScroll(delaySeconds: 3)
    }

2016-05-29 18-28-38

Page Control Dots Stop

By assigning .delegate property, the dots stops updating. Only images scroll fine.
Actually I wished to change a label based on the current slider. So to know if the slider has changed image, I needed to make my view controller a delegate of the uiscrollview and it stops changing dots...

How to loop images....

I would like to add 3 images to slideshow and keep them looping until i transition to next
viewController...

How to accomplish this?

Thanks for lib

Runtime Error: Library not loaded

Hi evgenyneu,

Im using version 2.0.19 right now, and my app compiles correctly. But now I have this runtime error as soon as the app loads in the simulator: dyld: Library not loaded: @rpath/Auk.framework/Auk Referenced from:XXXXX Reason: image not found

This never happened to me. I installed Auk through Cocoapods, and tried to re-create the pods 4 times already, including using 'pod deintegrate' to totally eliminate Pods from my project and re-creating them again, and still get this error.

please help.

Content size is too high

I think I'm using Auk as intended and have instantiated a UIScrollView from my storyboard. I have used

self.scrollView.auk.show(image: downloadedImage)

to set images. The problem is that content size is too high so that the images can be dragged vertically. When the first image is loaded a blank space above the image is visible. Please see attached screenshot.
contentsize_problem
The bottom part of the image is not visible, but at the top it's black (the UIScrollView background color).

Anything I'm doing wrong or is this a bug?

Auk inside a UITableViewCell

Hi Evgenii,

I just integrated Auk into my project (storyboard with auto layout). I have a ViewController hosting a TableViewController with a prototype cell. In this cell, there is a ScrollView that I am extending with Auk programatically and show two remote images with it.

When the view loads initially, everything works completely perfect. Both images are loading and the pageControl is moving as expected. But as soon as I scroll down the TableView and back up again, it destroys the ScrollView/Auk. I assume, that something goes wrong, when the cell is reused.

Do you have any experiences with Auk in TableViewCells?
Did I do anything wrong?

Thanks a lot and keep up the good work!
Frank

Scroll view will scroll or finished scrolling?

Hi!
Is there a way from the view controller to know if the scroll view started a scroll or finished? I need to update other views in the view controller accordingly. For example, each image has an author that took the picture and I want to show that name using the current index.

I saw that you use a delegate to load remote images when the superview becomes visible. It will be something similar but for local images.

Thanks!

Disable Image Dragging

I'm using AUK and everything is working perfect, but is there a way to disable images being draggable in views?

single image,not downloaded from url

hi, maybe its weird or there is something that i dont know about auks settings...
but when there is just one image in the slider, library doesn't download it... i am using it to show products images, but some of them has only one image, for this products, slider wouldn't download that one

Thread 1: EXC_BAD_INSTRUCTION

I use of plugin you. when the program start This error , "Thread 1:EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)” in line var value = Int(round(offset / width))

can you help me ?
i'm beginner in iOS programming.
thanks

Download Complete

Hey, everything is working perfectly well, except is there a way to check if the remote image has been downloaded, as i plan to show scrollview after all my images in the scrollview has been downloaded.

UIScrollViewDelegate is called too many times

Any reason for scrollViewDidScroll be called too many times? just curious!

override func viewDidLoad() {
    scrollView.auk.settings.preloadRemoteImagesAround = 2
    scrollView.auk.settings.showsHorizontalScrollIndicator = true
    scrollView.auk.settings.pageControl.visible = true
    scrollView.auk.settings.contentMode = UIViewContentMode.ScaleAspectFill

    let image1 = UIImage(named: "banner_top.jpg")
    self.scrollView.auk.show(image: image1!, accessibilityLabel: "Top")

    let image2 = UIImage(named: "banner_conteudo.jpg")
    self.scrollView.auk.show(image: image2!, accessibilityLabel: "Conteúdo")

    let image3 = UIImage(named: "banner_eventos.jpg")
    self.scrollView.auk.show(image: image3!, accessibilityLabel: "Eventos")

    scrollView.auk.startAutoScroll(delaySeconds: 3)
}
func scrollViewDidScroll(scrollView: UIScrollView) {
    print(scrollView.auk.currentPageIndex)
}
Optional(0)
Optional(0)
Optional(0)
Optional(0)
Optional(0)
Optional(0)
Optional(0)
Optional(0)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(1)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)
Optional(2)

Resize Remote Image

Hi,

I have a quick question here. Can I resize image from remote image before it showed? I think it will reduce memory usage on the apps. If there is any way to do it, let me know.

Thank you so much!

Touch Event

Hi, I love this library, it's much simpler and clearer than other carousel libraries.
I wonder if there is a simple way to handle touch events on each image.

For now, I'm adding a guesturerecognizer to the scrollview and
detecting touch events with currentPageIndex.
I just wanted to know if there's a more elegant way :)

let gesture = UITapGestureRecognizer(target: self, action: #selector(touchedScrollView))
scrollView!.addGestureRecognizer(gesture)

func touchedScrollView(sender: AnyObject) {
    print("touch \(scrollView!.auk.currentPageIndex)")
}

Building error in AukPageIndicatorContainer.swift / AutoCancellingTimer.swift

hi; your code is amazing and has helped me a lot. But after updating to 2.1.5 through cocoapods, Im getting this errors during building:

screen shot 2016-06-07 at 12 37 40 am

I think it refers to the '#' symbol you are using in #selector(..., but I've never had any problem since I started using it so I have no idea if this is a change with the update.

I hope you can take a look at this soon, or at least see if there was a difference back in version 2.0.19, which was working perfectly to me.

Thanks for your great effort; hail to the Great Auk!

click response

hi.
i have 3 image loaded from web
how i can detect which image is tapped?!
i'm beginner in iOS programming.
thanks

Page control is not visible

Hi,
page control is not visible if I'm setting images in viewDidLoad method:

`
@IBOutlet weak var carouselView: UIScrollView!
override func viewDidLoad() {
super.viewDidLoad()

    carouselView.auk.show(image: UIImage(named: "image1")!)
    carouselView.auk.show(image: UIImage(named: "image2")!)
    carouselView.auk.show(image: UIImage(named: "image3")!)
}

`

Use AUK on UIScrollView

I want to use Auk on UIScrollview, it can display all images, but i cant swipe left or right to change images, how to do that? so i can scroll up and down also swipe left or right on auk to change image

Adding text overlay to image.

Hi,

I'm not sure if this is the right place to ask. I am developing an APP and I am using your wonderful Auk slideshow. Is it possible to add a text or label that is overlaying on top of the image and that changes when the slider changes. The reason to add a label/text is that it could include email addresses or other types of interactive text that is pulled from other sources such as an sql database.

Thank you very much!

Auto scroll stops after changing the images by swiping manually

Hi .
Thanks for making this great library.I have a problem described in title.Here is my code.

        if let image = UIImage(named: "kampanyaslider1") {
            slider.auk.show(image: image)
        }
        if let image = UIImage(named: "kampanyaslider2") {
            slider.auk.show(image: image)
        }
        if let image = UIImage(named: "kampanyaslider3") {
            slider.auk.show(image: image)
        }
        slider.auk.startAutoScroll(delaySeconds: 3)

Is this expected behaviour? Thank you for you help.

image slider is not empty after view loads

Hi again,

I have another problem, maybe you can help me out.
Here's the app structure: TableViewController -> ViewController (loads the details from the selected cell)

When I click on a cell, everything is loading great and the slider works like a charm. However, if I go back to the tableviewcontroller (using navigation controller) and click on the same or another cell, then the image slider will show both the images from the previous cell + the ones from the new cell.

Even if I call the scrollView.auk.removeAll()...the slider disappear but when I scroll, they still appear. I'm thinking maybe it's another problem related to custom size classes?

Here's a code snippet from the viewController:

@IBOutlet weak var scrollView: UIScrollView!

override func viewDidAppear(animated: Bool) {
    createScrollView()
}


func createScrollView(){
       for app in appArray { //I have an array of structs            
        if app.appId == self.appId {

//self.appId comes from the selected cell and I'm searching for the struct with that id
for image in app.images {
let url = image //array of urls
self.scrollView.auk.show(url: url)
}
}

    }

}

Objective-c support

Hello,

I'm trying to integrate Auk into an Obective-c project using cocoapods.
I modified Auk class declaration to add @objc

@objc public class Auk : NSObject {

  public override init() {

  }

I added use_frameworks! to my podfile and set Defines Module to YES in my build settings.
In my class I import it like this
#import <Auk/Auk-Swift.h> //(I tried @import Auk; too)
and then :
[self.gallerySV.auk showWithUrl:imageUrl accessibilityLabel:nil];
The code is working but I only can access methodes in Auk.swfit (AukSettings for example is not recognised by Xcode ..)

Do you have any idea how to properly do this and do you intend to support integrating with objective-c (maybe in a branch ?)

Thanks !

Scroll not working

hello evgeny
I have an array that has three address
{...,"ImageAddress":["/Images/HotelImages/Parl-orumie.jpg","/Images/HotelImages/NULLradison_blue.jpg","/Images/HotelImages/safaeie.jpg"],... }

read json and save image in
imagesHotel : [String] = ["/Images/HotelImages/Parl-orumie.jpg","/Images/HotelImages/NULLradison_blue.jpg","/Images/HotelImages/safaeie.jpg"]


override func viewDidLoad() {

        super.viewDidLoad()
        implementation()
        Scrollable.createContentView(contentScrollView)
        scrollView.delegate = self
        scrollView.auk.settings.placeholderImage = UIImage(named: "1.png")
        scrollView.auk.settings.errorImage = UIImage(named: "1.png")
            self.HotelData() // json data 


                // Add segments

    }

When I want to show my photos and scroll , but scroll Does not work

/```
/ image show
func imageshow(){
scrollView.auk.removeAll()
print(imagesHotel)
for image in imagesHotel {
print(image)
let url = "(remoteImageBaseUrl)(image)"
scrollView.auk.show(url: url)

    }
    scrollView.auk.startAutoScroll(delaySeconds: 3.0)



}

ScrollView Infinite Looping

First of all, thank you so much for the project, love it a lot!
I wonder is it possible to add infinite looping for scrollView without much work? Now the looping is a bit weird, because if I hit the right-most view, and want it to go back to the first view, I will need to left-swift several times, rather than just right swipe one time.
If so, could you give me some suggestions so that I could add this feature and open a pull request maybe?

Page indicator is not showing

Hey,

First of all thank you for this image slideshow, your work is amazing.
I have some difficulties implementing your code and I don't understand where's the problem.
Everything is working great except the page indicator which is not showing.

Here's an extremely short version of your demo code that I've tried:

...
let remoteImageBaseUrl = "http://evgenii.com/files/2015/06/auk_demo/"
let remoteImages = [
(
fileName: "Alca_Impennis_by_John_Gould.jpg",
description: "Alca impennis by John Gould: The Birds of Europe, vol. 5 pl. 55, 19th century."
),
(
fileName: "Great_Auk_Egg_Bent.jpg",
description: "Great Auk egg, U. S. National Museum, in a book by Arthur Cleveland Bent, 1919."
),
(
fileName: "Great_auk_with_juvenile.jpg",
description: "Great auk with juvenile drawing by John Gerrard Keulemans, circa 1900."
),
(
fileName: "Keulemans-GreatAuk.jpg",
description: "Great Auks in summer and winter plumage by John Gerrard Keulemans, before 1912."
),
(
fileName: "SimlulateNoImage.jpg",
description: "No image test."
)
]

override func viewDidLoad() {
super.viewDidLoad()

    Moa.settings.cache.requestCachePolicy = .UseProtocolCachePolicy
    scrollView.delegate = self
    scrollView.auk.settings.placeholderImage = UIImage(named: "logo.png")
    scrollView.auk.settings.errorImage = UIImage(named: "error_image.png")
    //showInitialImage()
    scrollImages()
}


func scrollImages(){

    for image in remoteImages {
        let url = "\(remoteImageBaseUrl)\(image.fileName)"
        scrollView.auk.show(url: url)
    }

}

....

Where should I look?

Strange behaviour with remote images.

Hi

First incredible library, I was doing some testing and I have found some strange behaviour.

  1. I click on remote the images append perfect at scrollview but when I scroll it I see and animation from placeholder image to downloaded image ( even if the image is cached).
  2. If I scroll back and scroll again the fade effect disappear.

It looks strange behaviour when local images and remote are both in the slider the local images do not reproduce the fade effect and the remote images yes (but only the first time)

I hope I have explained.

Best regards
David

Shifting pageControl

Hi,

Me again. I was also trying to use the innerMargin property to move the pageControl in the x-axis but it doesn't seem to work. The CGSizeMake() values that I use work for the y-axis but not the x-axis. Is that possible?

Thank you!

How to update pageIndex?

Hi,
I don't understood how to update the index of Image. I've tried this way ( imageIndex is a label on my UIView) but it's doesn't work(

`override func viewDidLoad() {
super.viewDidLoad()

    if let scrollView = scrollView {
        scrollView.auk.show(image: UIImage(named: "image1")!)
        scrollView.auk.show(image: UIImage(named: "image2")!)

        imageIndex.text = String(scrollView.auk.currentPageIndex)
    }   
}

`
Always showed "Option(0)". I guess it's a pageIndex of first image but how I can update it? Where and when?

Thanks a lot and sorry, I'm a new coder. Your library is cool!

Image not loaded after setting scrollview delegate

Hello,

First of all this is an awesome library, congratulations for that.
I'm creating an app which uses more than one remote image and each image has a different label.
I followed your suggestion to track when the scrollview scrolls. I set the delegate, made all the necessary changes and the label changed according to the image, but it turned out the image stopped loading.
I removed the line that set the delegate and the image started loading again. Can you please tell me if this problem is already fixed or what I have to do to have all the images loading even when I'm using delegate?

Thanks in advance,
Renan.

Supplying complete XCode demo project

Hello,

Is it possible to supply a complete (working) XCode project to "Demo"? I think that would be very easy for many like me to just jump into the project source and give a run. At present I'm struggling just to run the supplied demo project.

Thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.