fixing name clobbering in qobjects.
Apparently qobjects need unique names or else they will name clobber.
This commit is contained in:
parent
f9e2d2c6dd
commit
da1c4f84b5
14 changed files with 57 additions and 60 deletions
|
@ -1,18 +1,14 @@
|
|||
use std::pin::Pin;
|
||||
|
||||
|
||||
use tokio::runtime::Runtime;
|
||||
use tracing::{debug, info};
|
||||
use tracing_subscriber::{
|
||||
EnvFilter,
|
||||
};
|
||||
use tracing_subscriber::EnvFilter;
|
||||
|
||||
use self::qobject::{QString, QUrl};
|
||||
use self::utils::{QString, QUrl};
|
||||
|
||||
mod db {
|
||||
use diesel::{Connection, SqliteConnection};
|
||||
use dirs::data_local_dir;
|
||||
|
||||
|
||||
pub enum Model {
|
||||
Songs,
|
||||
|
@ -51,7 +47,7 @@ mod db {
|
|||
}
|
||||
|
||||
#[cxx_qt::bridge]
|
||||
mod qobject {
|
||||
mod utils {
|
||||
unsafe extern "C++" {
|
||||
include!("cxx-qt-lib/qstring.h");
|
||||
type QString = cxx_qt_lib::QString;
|
||||
|
@ -91,7 +87,7 @@ impl Default for UtilsRust {
|
|||
}
|
||||
}
|
||||
|
||||
impl qobject::Utils {
|
||||
impl utils::Utils {
|
||||
pub fn setup(self: Pin<&mut Self>) {
|
||||
crate::utils::setup();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue