Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
ximper-welcome
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ximper Linux
ximper-welcome
Commits
cd0ab93c
Commit
cd0ab93c
authored
Dec 09, 2021
by
Christopher Davis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
general: Clean up warnings
We've had a few warnings sticking around for unused pieces of code, or things that needed some form of error handling.
parent
b5412aae
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
6 deletions
+8
-6
application.rs
src/application.rs
+0
-1
main.rs
src/main.rs
+8
-2
window.rs
src/widgets/window.rs
+0
-3
No files found.
src/application.rs
View file @
cd0ab93c
use
crate
::
config
;
use
crate
::
config
;
use
crate
::
utils
;
use
crate
::
utils
;
use
crate
::
widgets
::
Window
;
use
crate
::
widgets
::
Window
;
use
gtk
::
gdk
;
use
gtk
::
gio
::{
self
,
prelude
::
*
};
use
gtk
::
gio
::{
self
,
prelude
::
*
};
use
gtk
::
glib
::{
self
,
clone
};
use
gtk
::
glib
::{
self
,
clone
};
use
gtk
::
prelude
::
*
;
use
gtk
::
prelude
::
*
;
...
...
src/main.rs
View file @
cd0ab93c
...
@@ -14,8 +14,14 @@ fn main() {
...
@@ -14,8 +14,14 @@ fn main() {
pretty_env_logger
::
init
();
pretty_env_logger
::
init
();
// Prepare i18n
// Prepare i18n
setlocale
(
LocaleCategory
::
LcAll
,
""
);
setlocale
(
LocaleCategory
::
LcAll
,
""
);
bindtextdomain
(
GETTEXT_PACKAGE
,
LOCALEDIR
);
bindtextdomain
(
GETTEXT_PACKAGE
,
LOCALEDIR
)
.expect
(
&
format!
(
textdomain
(
GETTEXT_PACKAGE
);
"Unable to bind text domain for {}"
,
GETTEXT_PACKAGE
));
textdomain
(
GETTEXT_PACKAGE
)
.expect
(
&
format!
(
"Unable to switch to text domain {}"
,
GETTEXT_PACKAGE
));
glib
::
set_application_name
(
&
gettext
(
"Tour"
));
glib
::
set_application_name
(
&
gettext
(
"Tour"
));
glib
::
set_prgname
(
Some
(
"Tour"
));
glib
::
set_prgname
(
Some
(
"Tour"
));
...
...
src/widgets/window.rs
View file @
cd0ab93c
use
crate
::
utils
::
i18n_f
;
use
gettextrs
::
gettext
;
use
gettextrs
::
gettext
;
use
gtk
::
glib
;
use
gtk
::
glib
;
use
gtk
::
prelude
::
*
;
use
gtk
::
prelude
::
*
;
...
@@ -96,8 +95,6 @@ impl Window {
...
@@ -96,8 +95,6 @@ impl Window {
.upcast
::
<
gtk
::
Widget
>
(),
.upcast
::
<
gtk
::
Widget
>
(),
);
);
let
name
=
glib
::
os_info
(
"NAME"
)
.unwrap_or_else
(||
"GNOME"
.into
());
let
version
=
glib
::
os_info
(
"VERSION"
)
.unwrap_or_else
(||
""
.into
());
let
last_page
=
ImagePageWidget
::
new
(
let
last_page
=
ImagePageWidget
::
new
(
"/org/gnome/Tour/ready-to-go.svg"
,
"/org/gnome/Tour/ready-to-go.svg"
,
gettext
(
"That's it. Have a nice day!"
),
gettext
(
"That's it. Have a nice day!"
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment