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

Support native notification icons #8

Open
hmdebenque opened this issue Mar 12, 2018 · 3 comments
Open

Support native notification icons #8

hmdebenque opened this issue Mar 12, 2018 · 3 comments

Comments

@hmdebenque
Copy link

I am using linux notify-send module and I would want to use native icon instead of specifying one but API do not support it.

Please would you consider this feature ?

@jcgay
Copy link
Owner

jcgay commented Mar 13, 2018

Hi, what do you mean by native icon ? not setting an icon at all and let notify-send display a notification with its default behaviour ?

@calsirlerilor
Copy link

calsirlerilor commented Jul 9, 2018

Huh, not setting an Icon will throw an exception:

public static void main(String [] args) {
    Notifier notifier = new SendNotification()
                                .initNotifier();

    Notification notification = Notification.builder().level(Notification.Level.WARNING).message("test test test")
                                 .title("hello")
                                        .subtitle("world")
                                        .build();

    notifier.send(notification);


    notifier.close();
    System.out.println("exiting");
    System.exit(0);
  }

results in:
Exception in thread "main" java.lang.IllegalStateException: Missing required properties: icon
at fr.jcgay.notification.AutoValue_Notification$Builder.build(AutoValue_Notification.java:166)

@jcgay
Copy link
Owner

jcgay commented Aug 10, 2018

An icon is mandatory at the moment, because I haven't got any case where I don't need one.
But I guess I could go with a default behavior when none is set... ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants