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

Can anyone guide me into how to implement any of those features? #15

Open
XMOUFID opened this issue Sep 22, 2021 · 16 comments
Open

Can anyone guide me into how to implement any of those features? #15

XMOUFID opened this issue Sep 22, 2021 · 16 comments

Comments

@XMOUFID
Copy link

XMOUFID commented Sep 22, 2021

Im completely new to all of this but find what you guys accomplish fascinating and I would love to implement them, how do I do that, also I realize this isn't exactly an issue, I couldn't find a way to contact you, and I've look around for tutorials and such, but they didn't help, if you could just provide a link or something to a guide that would be highly appreciated, thank you so much in advance! @l2dy @augo @giedrius-stanevicius @Ashinch anyone

@Ashinch
Copy link
Contributor

Ashinch commented Oct 1, 2021

Hey @XMOUFID , I am very sorry that my response is late because I have not recently concerned about this. Do you want to contribute to this project?

@XMOUFID
Copy link
Author

XMOUFID commented Oct 2, 2021

@Ashinch no it's okay, I just would like if you could give me a simple guide or provide a link that explains the process of adding those features mentioned in the project, because when I install it, I don't get some of them like the battery percentage etc, so I assumed I have to do something else to implement them, if that's the case then any additional info would be appreciated, again thanks a lot!

@Ashinch
Copy link
Contributor

Ashinch commented Oct 2, 2021

@Ashinch no it's okay, I just would like if you could give me a simple guide or provide a link that explains the process of adding those features mentioned in the project, because when I install it, I don't get some of them like the battery percentage etc, so I assumed I have to do something else to implement them, if that's the case then any additional info would be appreciated, again thanks a lot!

Hey @XMOUFID, if you are DMG program downloaded from the Soduto website, it is that it is old, does not contain recent changes.

Want to get the latest commit, you need clone this repo, then manually build in Xcode, maybe you need to update the dependent library, this may not be smooth, maybe you can contact @giedrius-stanevicius , let him share a newest DMG program.

@XMOUFID
Copy link
Author

XMOUFID commented Oct 3, 2021

@Ashinch yes I tried building it before, it shows up with many errors, thanks a lot for being helpful though, it's highly appreciated, and about @giedrius-stanevicius he doesn't seem to be active at the moment nor do I know of any way to reach him, also, is there a way you can send yours instead for now? but no pressure if you're busy. thanks once again!

@giedrius-stanevicius
Copy link
Collaborator

giedrius-stanevicius commented Oct 4, 2021

Hi @XMOUFID, sorry for delay answering. Currently I don't have a working build setup for Soduto, also I need to renew Apple developer subscription in order to be able to produce properly signed app binary. I've been quite busy lately, so I am not sure when I'll find time for all this. Will try to do it sooner, though.

@Ashinch
Copy link
Contributor

Ashinch commented Oct 4, 2021

... is there a way you can send yours instead for now...

@XMOUFID, Yes, as @giedrius-stanevicius said, I have no latest version of DMG here, I am sorry.

@XMOUFID
Copy link
Author

XMOUFID commented Oct 4, 2021

@giedrius-stanevicius it's okay, take your time, not trying to add more pressure, and thanks a lot!

@XMOUFID, Yes, as @giedrius-stanevicius said, I have no latest version of DMG here, I am sorry.

@Ashinch no need to be sorry I understand, thanks though, you've been very helpful.

@whispy
Copy link

whispy commented Feb 2, 2022

@giedrius-stanevicius would you be willing to accept a bounty to help out with getting the app updated and renewing your apple developer subscription?

@giedrius-stanevicius
Copy link
Collaborator

@whispy, can you write an email to [email protected] with details about what your needs are and what kind of bounty are you suggesting? Maybe we will manage to arrange something ;)

@sannidhyaroy
Copy link

@giedrius-stanevicius Can you tell me how I can access the notification access button from the received data packet from KDE Connect?

As a reference, this is the method which is written in the NotificationsService.swift file for accessing the App Name:

func getAppName() throws -> String? {
    try self.validateNotificationType()
    guard body.keys.contains(NotificationProperty.appName.rawValue) else { return nil }
    guard let value = body[NotificationProperty.appName.rawValue] as? String else { throw NotificationError.invalidAppName }
    return value
}

I want to get the list of action buttons in a similar way but haven't found a solution. I know it's possible as KDE Connect on Linux and other platforms can do this. Any idea?

@yurikoles
Copy link

@giedrius-stanevicius
Copy link
Collaborator

giedrius-stanevicius commented Dec 13, 2022

@sannidhyaroy What kind of action buttons do you have in mind? Looking at KDE Connect notifications plugin description (https://github.com/KDE/kdeconnect-kde/tree/master/plugins/notifications) it does not seem there are any possible actions except dismiss and reply

@giedrius-stanevicius
Copy link
Collaborator

@sannidhyaroy Ok, it seems there are actions, only README is not updated there. You may check https://github.com/KDE/kdeconnect-kde/blob/master/plugins/notifications/notification.cpp - at the bottom there is a function that parses the packet and extracts the actions and other notification properties.

@sannidhyaroy
Copy link

sannidhyaroy commented Dec 13, 2022

@giedrius-stanevicius After looking at the code for KDE Connect desktop app's notification plugin, I was able to get the action buttons as an array of strings. However, they obviously don't perform any kind of action in response to clicks as I can't figure out how to send a request to the other device to carry out the necessary operation.
Screenshot 2022-12-13 at 5 40 37 PM

@giedrius-stanevicius
Copy link
Collaborator

@sannidhyaroy KDE connect uses such code to send action. So you should make the same kind of packet too:

void NotificationsPlugin::sendAction(const QString &key, const QString &action)
{
    NetworkPacket np(PACKET_TYPE_NOTIFICATION_ACTION);
    np.set<QString>(QStringLiteral("key"), key);
    np.set<QString>(QStringLiteral("action"), action);
    sendPacket(np);
}

@sannidhyaroy
Copy link

@giedrius-stanevicius Thanks a lot! I was struggling with this for the past few days without making any progress but was finally able to successfully implement the feature, thanks to your immediate help!

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

6 participants