Skip to content

Commit

Permalink
refactor(v23): Merge branch 'develop/snipe'
Browse files Browse the repository at this point in the history
  • Loading branch information
BLumia committed Jan 31, 2023
2 parents 6013c6d + 3dfdd76 commit 862dfbf
Show file tree
Hide file tree
Showing 141 changed files with 321 additions and 292 deletions.
8 changes: 4 additions & 4 deletions .tx/config
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
host = https://www.transifex.com

[deepin-desktop-environment.dde-api-locale-helper-policyts]
file_filter = misc/ts/com.deepin.api.locale-helper.policy/policy_<lang>.ts
source_file = misc/ts/com.deepin.api.locale-helper.policy/policy.ts
file_filter = misc/ts/org.deepin.dde.locale-helper.policy/policy_<lang>.ts
source_file = misc/ts/org.deepin.dde.locale-helper.policy/policy.ts
source_lang = en
type = QT

[deepin-desktop-environment.dde-api-device-unblock-bt-devices-policyts]
file_filter = misc/ts/com.deepin.api.device.unblock-bluetooth-devices.policy/policy_<lang>.ts
source_file = misc/ts/com.deepin.api.device.unblock-bluetooth-devices.policy/policy.ts
file_filter = misc/ts/org.deepin.dde.device.unblock-bluetooth-devices.policy/policy_<lang>.ts
source_file = misc/ts/org.deepin.dde.device.unblock-bluetooth-devices.policy/policy.ts
source_lang = en
type = QT

8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@ prepare:
@ln -snf ../../../.. ${GOBUILD_DIR}/src/${GOPKG_PREFIX};

ts:
deepin-policy-ts-convert policy2ts misc/polkit-action/com.deepin.api.locale-helper.policy.in misc/ts/com.deepin.api.locale-helper.policy
deepin-policy-ts-convert policy2ts misc/polkit-action/com.deepin.api.device.unblock-bluetooth-devices.policy.in misc/ts/com.deepin.api.device.unblock-bluetooth-devices.policy
deepin-policy-ts-convert policy2ts misc/polkit-action/org.deepin.dde.locale-helper.policy.in misc/ts/org.deepin.dde.locale-helper.policy
deepin-policy-ts-convert policy2ts misc/polkit-action/org.deepin.dde.device.unblock-bluetooth-devices.policy.in misc/ts/org.deepin.dde.device.unblock-bluetooth-devices.policy

ts-to-policy:
deepin-policy-ts-convert ts2policy misc/polkit-action/com.deepin.api.locale-helper.policy.in misc/ts/com.deepin.api.locale-helper.policy misc/polkit-action/com.deepin.api.locale-helper.policy
deepin-policy-ts-convert ts2policy misc/polkit-action/com.deepin.api.device.unblock-bluetooth-devices.policy.in misc/ts/com.deepin.api.device.unblock-bluetooth-devices.policy misc/polkit-action/com.deepin.api.device.unblock-bluetooth-devices.policy
deepin-policy-ts-convert ts2policy misc/polkit-action/org.deepin.dde.locale-helper.policy.in misc/ts/org.deepin.dde.locale-helper.policy misc/polkit-action/org.deepin.dde.locale-helper.policy
deepin-policy-ts-convert ts2policy misc/polkit-action/org.deepin.dde.device.unblock-bluetooth-devices.policy.in misc/ts/org.deepin.dde.device.unblock-bluetooth-devices.policy misc/polkit-action/org.deepin.dde.device.unblock-bluetooth-devices.policy

out/bin/%:
${GOBUILD} -o $@ ${GOBUILD_OPTIONS} ${GOPKG_PREFIX}/${@F}
Expand Down
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ DDE API provides some dbus interfaces that is used for screen zone detecting, th

## Dependencies


### Build Dependencies

* [go-lib](https://github.com/linuxdeepin/go-lib)
Expand Down
2 changes: 1 addition & 1 deletion adjust-grub-theme/testdata/grub
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Written by com.deepin.daemon.Grub2
# Written by org.deepin.daemon.Grub2
DEEPIN_GFXMODE_DETECT=2
GRUB_BACKGROUND=/boot/grub/themes/deepin-fallback/background.jpg
GRUB_CMDLINE_LINUX=""
Expand Down
6 changes: 3 additions & 3 deletions cursor-helper/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ func (*Manager) GetInterfaceName() string {
}

const (
dbusServiceName = "com.deepin.api.CursorHelper"
dbusPath = "/com/deepin/api/CursorHelper"
dbusInterface = "com.deepin.api.CursorHelper"
dbusServiceName = "org.deepin.dde.CursorHelper1"
dbusPath = "/org/deepin/dde/CursorHelper1"
dbusInterface = "org.deepin.dde.CursorHelper1"
)

var logger = log.NewLogger("api/cursor-helper")
Expand Down
6 changes: 3 additions & 3 deletions dde-open/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ import (
"path/filepath"

"github.com/godbus/dbus"
"github.com/linuxdeepin/go-dbus-factory/com.deepin.sessionmanager"
"github.com/linuxdeepin/go-gir/gio-2.0"
startmanager "github.com/linuxdeepin/go-dbus-factory/session/org.deepin.dde.startmanager1"
gio "github.com/linuxdeepin/go-gir/gio-2.0"
"github.com/linuxdeepin/go-lib/log"
)

Expand Down Expand Up @@ -70,7 +70,7 @@ func launchApp(desktopFile, filename string) error {
if err != nil {
return err
}
startManager := sessionmanager.NewStartManager(sessionBus)
startManager := startmanager.NewStartManager(sessionBus)
err = startManager.LaunchApp(dbus.FlagNoAutoStart, desktopFile, 0,
[]string{filename})
return err
Expand Down
39 changes: 36 additions & 3 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,8 +1,41 @@
dde-api (3.0.11) unstable; urgency=low
dde-api (6.0.4) unstable; urgency=medium

* update deepin-boot-sound.sh interpreter
[ TagBuilder ]
* fix: grub2主题配置不生效(Task: 177439)(Influence: grub主题)

-- lichangze <[email protected]> Fri, 30 Aug 2022 18:44:23 +0000
-- zhaoyingzhen <[email protected]> Thu, 29 Dec 2022 14:59:32 +0800

dde-api (6.0.3) unstable; urgency=medium

[ TagBuilder ]
* feat: 接口更变,增加V23接口(Task: 207483)(Influence: 接口更变)

-- zhaoyingzhen <[email protected]> Tue, 13 Dec 2022 18:40:51 +0800

dde-api (6.0.2) unstable; urgency=medium

* release 6.0.2

-- <[email protected]> Wed, 19 Oct 2022 11:24:27 +0800

dde-api (6.0.1) unstable; urgency=medium

[ cxr@cxr-PC ]
* UNRELEASED

-- caixiangrong <[email protected]> Mon, 25 Jul 2022 14:06:59 +0800

dde-api (6.0.0.1) unstable; urgency=medium

* 6.0.0.1 Modified go-lib to trigger DDE-API synchronously

-- <[email protected]> Mon, 25 Jul 2022 07:25:57 +0800

dde-api (6.0.0.0) UNRELEASED; urgency=medium

* 6.0.0.0 pre-release

-- <[email protected]> Wed, 01 Jun 2022 11:21:57 +0800

dde-api (3.0.10-1) unstable; urgency=low

Expand Down
4 changes: 1 addition & 3 deletions debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,9 @@ Depends:
fontconfig,
fonts-noto-cjk,
libcanberra-pulse,
librsvg2-bin,
libsqlite3-0,
locales,
rfkill,
ttf-unifont | fonts-unifont,
fonts-unifont,
${misc:Depends},
${shlibs:Depends},
Description: Go-lang bingdings for dde-daemon
Expand Down
4 changes: 1 addition & 3 deletions debian/postinst
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,7 @@ case "$1" in
runuser -u $player_user -- mkdir -p $player_home/.config/pulse
runuser - deepin-sound-player -s /bin/sh -c "echo 'autospawn = no' > $player_home/.config/pulse/client.conf"

if [ -f $grubCfgFile -a -f /etc/default/grub ]; then
adjustGrubTheme
fi
adjustGrubTheme
setupFallbackTheme
;;
abort-upgrade|abort-remove|abort-deconfigure)
Expand Down
8 changes: 4 additions & 4 deletions device/device.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,18 @@ import (
"github.com/godbus/dbus"
"github.com/linuxdeepin/go-lib/dbusutil"

polkit "github.com/linuxdeepin/go-dbus-factory/org.freedesktop.policykit1"
polkit "github.com/linuxdeepin/go-dbus-factory/system/org.freedesktop.policykit1"
)

//go:generate dbusutil-gen em -type Device

const (
dbusServiceName = "com.deepin.api.Device"
dbusPath = "/com/deepin/api/Device"
dbusServiceName = "org.deepin.dde.Device1"
dbusPath = "/org/deepin/dde/Device1"
dbusInterface = dbusServiceName
rfkillBin = "rfkill"
rfkillDeviceTypeBluetooth = "bluetooth"
unblockBluetoothDevicesActionId = "com.deepin.api.device.unblock-bluetooth-devices"
unblockBluetoothDevicesActionId = "org.deepin.dde.device.unblock-bluetooth-devices"
)

type Device struct {
Expand Down
2 changes: 1 addition & 1 deletion dxinput/kwayland/inputdevice.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (

"github.com/godbus/dbus"
. "github.com/linuxdeepin/dde-api/dxinput/common"
kwin "github.com/linuxdeepin/go-dbus-factory/org.kde.kwin"
kwin "github.com/linuxdeepin/go-dbus-factory/session/org.kde.kwin"
)

const (
Expand Down
6 changes: 3 additions & 3 deletions graphic/graphic.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ import (
//go:generate dbusutil-gen em -type Graphic

const (
dbusServiceName = "com.deepin.api.Graphic"
dbusPath = "/com/deepin/api/Graphic"
dbusInterface = "com.deepin.api.Graphic"
dbusServiceName = "org.deepin.dde.Graphic1"
dbusPath = "/org/deepin/dde/Graphic1"
dbusInterface = "org.deepin.dde.Graphic1"
)

// Graphic is a dbus interface wrapper for github.com/linuxdeepin/go-lib/graphic.
Expand Down
4 changes: 2 additions & 2 deletions hans2pinyin/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ import (
//go:generate dbusutil-gen em -type Manager

const (
dbusServiceName = "com.deepin.api.Pinyin"
dbusPath = "/com/deepin/api/Pinyin"
dbusServiceName = "org.deepin.dde.Pinyin1"
dbusPath = "/org/deepin/dde/Pinyin1"
dbusInterface = dbusServiceName
)

Expand Down
4 changes: 2 additions & 2 deletions inhibit_hint/inhibit_hint.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ import (
//go:generate dbusutil-gen em -type Object

const (
dbusPath = "/com/deepin/InhibitHint"
dbusInterface = "com.deepin.InhibitHint"
dbusPath = "/org/deepin/dde/InhibitHint1"
dbusInterface = "org.deepin.dde.InhibitHint1"
)

type Object struct {
Expand Down
4 changes: 2 additions & 2 deletions locale-helper/ifc.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ package main
import (
"fmt"

polkit "github.com/linuxdeepin/go-dbus-factory/org.freedesktop.policykit1"
"github.com/godbus/dbus"
polkit "github.com/linuxdeepin/go-dbus-factory/system/org.freedesktop.policykit1"
"github.com/linuxdeepin/go-lib/dbusutil"
dutils "github.com/linuxdeepin/go-lib/utils"
)

const (
polkitManageLocale = "com.deepin.api.locale-helper.manage-locale"
polkitManageLocale = "org.deepin.dde.locale-helper.manage-locale"

defaultLocaleFile = "/etc/default/locale"
defaultLocaleGenFile = "/etc/locale.gen"
Expand Down
4 changes: 2 additions & 2 deletions locale-helper/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ import (
//go:generate dbusutil-gen em -type Helper

const (
dbusServiceName = "com.deepin.api.LocaleHelper"
dbusPath = "/com/deepin/api/LocaleHelper"
dbusServiceName = "org.deepin.dde.LocaleHelper1"
dbusPath = "/org/deepin/dde/LocaleHelper1"
dbusInterface = dbusServiceName
localeGenBin = "locale-gen"
)
Expand Down
8 changes: 4 additions & 4 deletions lunar-calendar/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@ import (
"strings"

"github.com/godbus/dbus"
libdate "github.com/rickb777/date"
"github.com/linuxdeepin/go-lib/calendar"
"github.com/linuxdeepin/go-lib/calendar/lunar"
"github.com/linuxdeepin/go-lib/dbusutil"
libdate "github.com/rickb777/date"
)

//go:generate dbusutil-gen em -type Manager

const (
dbusServiceName = "com.deepin.api.LunarCalendar"
dbusPath = "/com/deepin/api/LunarCalendar"
dbusInterface = "com.deepin.api.LunarCalendar"
dbusServiceName = "org.deepin.dde.LunarCalendar1"
dbusPath = "/org/deepin/dde/LunarCalendar1"
dbusInterface = "org.deepin.dde.LunarCalendar1"
)

type Manager struct {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,18 @@

<!-- Only root can own the service -->
<policy user="root">
<allow own="com.deepin.api.Device"/>
<allow own="org.deepin.dde.Device1"/>
</policy>

<!-- Allow anyone to invoke methods on the interfaces -->
<policy context="default">
<allow send_destination="com.deepin.api.Device" />
<allow send_destination="org.deepin.dde.Device1" />

<allow send_destination="com.deepin.api.Device"
send_interface="com.deepin.api.Device"/>
<allow send_destination="com.deepin.api.Device"
<allow send_destination="org.deepin.dde.Device1"
send_interface="org.deepin.dde.Device1"/>
<allow send_destination="org.deepin.dde.Device1"
send_interface="org.freedesktop.DBus.Properties"/>
<allow send_destination="com.deepin.api.Device"
<allow send_destination="org.deepin.dde.Device1"
send_interface="org.freedesktop.DBus.Introspectable"/>
</policy>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,18 @@

<!-- Only root can own the service -->
<policy user="root">
<allow own="com.deepin.api.LocaleHelper"/>
<allow own="org.deepin.dde.LocaleHelper1"/>
</policy>

<!-- Allow anyone to invoke methods on the interfaces -->
<policy context="default">
<allow send_destination="com.deepin.api.LocaleHelper" />
<allow send_destination="org.deepin.dde.LocaleHelper1" />

<allow send_destination="com.deepin.api.LocaleHelper"
send_interface="com.deepin.api.LocaleHelper"/>
<allow send_destination="com.deepin.api.LocaleHelper"
<allow send_destination="org.deepin.dde.LocaleHelper1"
send_interface="org.deepin.dde.LocaleHelper1"/>
<allow send_destination="org.deepin.dde.LocaleHelper1"
send_interface="org.freedesktop.DBus.Properties"/>
<allow send_destination="com.deepin.api.LocaleHelper"
<allow send_destination="org.deepin.dde.LocaleHelper1"
send_interface="org.freedesktop.DBus.Introspectable"/>
</policy>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@

<!-- Only user deepin-sound-player can own the service -->
<policy user="deepin-sound-player">
<allow own="com.deepin.api.SoundThemePlayer"/>
<allow own="org.deepin.dde.SoundThemePlayer1"/>
</policy>

<!-- Allow anyone to invoke methods on the interfaces -->
<policy context="default">
<allow send_destination="com.deepin.api.SoundThemePlayer" />
<allow send_destination="org.deepin.dde.SoundThemePlayer1" />
</policy>

</busconfig>
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<vendor/>
<vendor_url/>

<action id="com.deepin.api.device.unblock-bluetooth-devices">
<action id="org.deepin.dde.device.unblock-bluetooth-devices">
<description>Unblock bluetooth devices</description>
<message>Authentication is required to unblock bluetooth devices</message>
<defaults>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<vendor/>
<vendor_url/>

<action id="com.deepin.api.locale-helper.manage-locale">
<action id="org.deepin.dde.locale-helper.manage-locale">
<description>Manage your system locale</description>
<message>Authentication is required to switch language</message>
<defaults>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[Unblock bluetooth devices]
Identity=unix-group:sudo
Action=com.deepin.api.device.unblock-bluetooth-devices
Action=org.deepin.dde.device.unblock-bluetooth-devices
ResultAny=no
ResultInactive=no
ResultActive=yes
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[D-BUS Service]
Name=com.deepin.api.CursorHelper
Name=org.deepin.dde.CursorHelper1
Exec=/usr/lib/deepin-api/cursor-helper
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[D-BUS Service]
Name=com.deepin.api.Graphic
Name=org.deepin.dde.Graphic1
Exec=/usr/lib/deepin-api/graphic
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[D-BUS Service]
Name=com.deepin.api.LunarCalendar
Name=org.deepin.dde.LunarCalendar1
#Exec=/usr/lib/deepin-api/lunar-calendar
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[D-BUS Service]
Name=com.deepin.api.Pinyin
Name=org.deepin.dde.Pinyin1
Exec=/usr/lib/deepin-api/hans2pinyin
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[D-BUS Service]
Name=com.deepin.api.Device
Name=org.deepin.dde.Device1
Exec=/usr/lib/deepin-api/device
User=root
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[D-BUS Service]
Name=com.deepin.api.LocaleHelper
Name=org.deepin.dde.LocaleHelper1
Exec=/usr/lib/deepin-api/locale-helper
User=root
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[D-BUS Service]
Name=com.deepin.api.SoundThemePlayer
Name=org.deepin.dde.SoundThemePlayer1
Exec=/usr/lib/deepin-api/sound-theme-player
User=deepin-sound-player
Loading

0 comments on commit 862dfbf

Please sign in to comment.