Giter VIP home page Giter VIP logo

libsparkcolourpicker's People

Contributors

sparkdev97 avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar

libsparkcolourpicker's Issues

SparkColourPickerCell not showing correctly unless a different tweak is installed

I'm working on integrating libSparkColourPicker into my tweak, but I can only get the SparkColourPickerCell to show if I have another tweak that depends on libSparkColourPicker installed. For example: If I install my tweak (ZenithDark), and make sure libSparkColourPicker is installed, the cell where the color picker should be shows up looking like a cell that is used for multi-page prefs (See first attached screenshot). However, when I install a tweak that utilizes libSparkColourPicker, it works fine (See second screenshot). I can't figure out why this is happening!

I've double checked that it's not another tweak messing with it, so I'm not sure what to do now.

Thanks!

IMG_914F87A71F4C-1

IMG_0410

Error when compiling

Error:

Undefined symbols for architecture armv7:
  "_OBJC_CLASS_$_SparkColourPickerUtils", referenced from:
      objc-class-ref in Tweak.xm.b1b545ed.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Color reverting back to fallback

I'm trying to make a switch that controls whether or not my tweak should use a custom color, and my code looks something like this:

`-(void)setBackgroundColor:(UIColor *)backgroundColor {

NSString* colourString = NULL;
NSDictionary* preferencesDictionary = [NSDictionary dictionaryWithContentsOfFile: @"/var/mobile/Library/Preferences/com.mac-user669.zenithdark.plist"];
if(preferencesDictionary)
{
    colourString = [preferencesDictionary objectForKey: @"aColorOfMine"];
}
UIColor* selectedColour = [SparkColourPickerUtils colourWithString: colourString withFallback: @"#FF00FF"];
if (@available(iOS 13, *)) {
if (self.traitCollection.userInterfaceStyle == UIUserInterfaceStyleDark) {
   if (kCustomDarkColorEnabled) {

   %orig(selectedColour); 
}
else {
   %orig([UIColor blueColor]);
}
}

else {
%orig;
}

}
}`

Everything works fine until I turn off kCustomDarkColorEnabled and respring, and then the color goes back to the fallback color. What am I doing wrong?

Thanks!

Edit: To clarify, the SparkColourPicker's color gets totally removed from the preference file

Support for iOS 14?

Please make LSColourPicker for iOS 14. Thanks!!

(on iOS 14 if you use colour picker and click any slider or any colour it crashes that app)

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.