More rebrand, made ToS not shit
This commit is contained in:
37
Cargo.lock
generated
37
Cargo.lock
generated
@ -1270,6 +1270,25 @@ dependencies = [
|
||||
"web-sys",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "is-docker"
|
||||
version = "0.2.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "928bae27f42bc99b60d9ac7334e3a21d10ad8f1835a4e12ec3ec0464765ed1b3"
|
||||
dependencies = [
|
||||
"once_cell",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "is-wsl"
|
||||
version = "0.4.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "173609498df190136aa7dea1a91db051746d339e18476eed5ca40521f02d7aa5"
|
||||
dependencies = [
|
||||
"is-docker",
|
||||
"once_cell",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "jni-sys"
|
||||
version = "0.3.0"
|
||||
@ -1669,6 +1688,17 @@ version = "1.19.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92"
|
||||
|
||||
[[package]]
|
||||
name = "open"
|
||||
version = "5.1.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "449f0ff855d85ddbf1edd5b646d65249ead3f5e422aaa86b7d2d0b049b103e32"
|
||||
dependencies = [
|
||||
"is-wsl",
|
||||
"libc",
|
||||
"pathdiff",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "ordered-float"
|
||||
version = "4.2.0"
|
||||
@ -1759,6 +1789,12 @@ dependencies = [
|
||||
"windows-targets 0.48.5",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "pathdiff"
|
||||
version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd"
|
||||
|
||||
[[package]]
|
||||
name = "percent-encoding"
|
||||
version = "2.3.1"
|
||||
@ -3131,6 +3167,7 @@ dependencies = [
|
||||
"iced",
|
||||
"image",
|
||||
"native-dialog",
|
||||
"open",
|
||||
"steamworks",
|
||||
]
|
||||
|
||||
|
@ -6,7 +6,7 @@ edition = "2021"
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[[bin]]
|
||||
name="WaniWorkshop"
|
||||
name="wani_workshop"
|
||||
path="src/main.rs"
|
||||
|
||||
[dependencies]
|
||||
@ -14,3 +14,4 @@ steamworks = "0.9.0"
|
||||
iced = "0.6"
|
||||
native-dialog = "0.6.3"
|
||||
image = "0.24.7"
|
||||
open = "5.1.2"
|
||||
|
BIN
assets/icon.png
BIN
assets/icon.png
Binary file not shown.
Before Width: | Height: | Size: 869 B After Width: | Height: | Size: 4.6 KiB |
BIN
assets/icon_full.png
Normal file
BIN
assets/icon_full.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 96 KiB |
@ -55,29 +55,37 @@ impl ItemInfoState {
|
||||
|
||||
pub fn view(&self, file_id: Option<PublishedFileId>) -> Element<ItemInfoMessage> {
|
||||
column![
|
||||
text(" "),
|
||||
text(" "),
|
||||
if let Some(file_id) = file_id {
|
||||
text(format!("Updating item with ID: {}", file_id.0))
|
||||
} else {
|
||||
text("Creating new item:")
|
||||
},
|
||||
text(" "),
|
||||
text_input("Name", &self.name, ItemInfoMessage::EditName,),
|
||||
text(" "),
|
||||
self.preview_image.view(
|
||||
"Preview Image",
|
||||
if file_id.is_some() { "Optional" } else { "" },
|
||||
ItemInfoMessage::EditPreviewImage,
|
||||
ItemInfoMessage::BrowsePreviewImage,
|
||||
),
|
||||
text(" "),
|
||||
self.target_folder.view(
|
||||
"Target Folder",
|
||||
"",
|
||||
ItemInfoMessage::EditTargetFolder,
|
||||
ItemInfoMessage::BrowseTargetFolder,
|
||||
),
|
||||
text(" "),
|
||||
text(" "),
|
||||
text_input(
|
||||
"Changenotes",
|
||||
&self.change_notes,
|
||||
ItemInfoMessage::EditChangeNotes
|
||||
)
|
||||
),
|
||||
text(" ")
|
||||
]
|
||||
.into()
|
||||
}
|
||||
|
15
src/main.rs
15
src/main.rs
@ -61,7 +61,11 @@ fn initial_view<'a>(existing_id: &str) -> Element<'a, Message> {
|
||||
let item_id = existing_id.parse::<u64>().map(PublishedFileId);
|
||||
|
||||
let mut res = column![
|
||||
text("4onen's Steam Workshop Uploader"),
|
||||
text(" "),
|
||||
text(" "),
|
||||
text("I Wani Hug That Gator Steam Workshop Uploader"),
|
||||
text(" "),
|
||||
text(" "),
|
||||
if let Err(error) = &item_id {
|
||||
if *error.kind() == IntErrorKind::Empty {
|
||||
button("Create new").on_press(Message::Proceed)
|
||||
@ -71,6 +75,7 @@ fn initial_view<'a>(existing_id: &str) -> Element<'a, Message> {
|
||||
} else {
|
||||
button("Update existing").on_press(Message::Proceed)
|
||||
},
|
||||
text(" "),
|
||||
text_input("Existing item ID", existing_id, Message::SetExistingId)
|
||||
.on_submit(Message::Proceed),
|
||||
];
|
||||
@ -105,10 +110,12 @@ fn edit_item_view<'a>(
|
||||
.view(existing_id)
|
||||
.map(move |message| Message::EditItemData(message)),
|
||||
column![
|
||||
text(" "),
|
||||
text("By submitting this item, you agree to the Steam workshop"),
|
||||
button("Terms of Service").on_press(Message::TermsLinkPressed)
|
||||
button("Terms of Service").on_press(Message::TermsLinkPressed),
|
||||
text(" ")
|
||||
],
|
||||
row![button("Go back").on_press(Message::GoBack), fwd_button],
|
||||
row![button("Go back").on_press(Message::GoBack),text(" "), fwd_button],
|
||||
match ready_info {
|
||||
Ok(_) => text(""),
|
||||
Err(error) => text(format!("{}", error)),
|
||||
@ -149,7 +156,7 @@ impl Application for Model {
|
||||
}
|
||||
|
||||
fn title(&self) -> String {
|
||||
String::from("4onen's Workshop Uploader")
|
||||
String::from("Wani Workshop Uploader")
|
||||
}
|
||||
|
||||
fn update(&mut self, message: Self::Message) -> Command<Message> {
|
||||
|
@ -115,9 +115,10 @@ impl WorkshopClient {
|
||||
}
|
||||
|
||||
pub fn open_url(&self, url: &str) -> () {
|
||||
self.steam_client
|
||||
.friends()
|
||||
.activate_game_overlay_to_web_page(url)
|
||||
// self.steam_client
|
||||
// .friends()
|
||||
// .activate_game_overlay_to_web_page(url)
|
||||
let _ = open::that(url);
|
||||
}
|
||||
|
||||
pub fn open_terms(&self) -> () {
|
||||
|
Reference in New Issue
Block a user