Skip to content

Commit 2e75471

Browse files
committed
docs(dialog): add/fix doc item links, closes #3089
1 parent 1a03e97 commit 2e75471

File tree

1 file changed

+33
-6
lines changed

1 file changed

+33
-6
lines changed

plugins/dialog/src/lib.rs

Lines changed: 33 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -467,10 +467,11 @@ impl<R: Runtime> FileDialogBuilder<R> {
467467
}
468468

469469
/// Shows the dialog to select a single file.
470+
///
470471
/// This is not a blocking operation,
471472
/// and should be used when running on the main thread to avoid deadlocks with the event loop.
472473
///
473-
/// For usage in other contexts such as commands, prefer [`Self::pick_file`].
474+
/// See [`Self::blocking_pick_file`] for a blocking version for use in other contexts.
474475
///
475476
/// # Examples
476477
///
@@ -490,9 +491,12 @@ impl<R: Runtime> FileDialogBuilder<R> {
490491
}
491492

492493
/// Shows the dialog to select multiple files.
494+
///
493495
/// This is not a blocking operation,
494496
/// and should be used when running on the main thread to avoid deadlocks with the event loop.
495497
///
498+
/// See [`Self::blocking_pick_files`] for a blocking version for use in other contexts.
499+
///
496500
/// # Reading the files
497501
///
498502
/// The file paths cannot be read directly on Android as they are behind a content URI.
@@ -535,9 +539,12 @@ impl<R: Runtime> FileDialogBuilder<R> {
535539
}
536540

537541
/// Shows the dialog to select a single folder.
542+
///
538543
/// This is not a blocking operation,
539544
/// and should be used when running on the main thread to avoid deadlocks with the event loop.
540545
///
546+
/// See [`Self::blocking_pick_folder`] for a blocking version for use in other contexts.
547+
///
541548
/// # Examples
542549
///
543550
/// ```
@@ -557,9 +564,12 @@ impl<R: Runtime> FileDialogBuilder<R> {
557564
}
558565

559566
/// Shows the dialog to select multiple folders.
567+
///
560568
/// This is not a blocking operation,
561569
/// and should be used when running on the main thread to avoid deadlocks with the event loop.
562570
///
571+
/// See [`Self::blocking_pick_folders`] for a blocking version for use in other contexts.
572+
///
563573
/// # Examples
564574
///
565575
/// ```
@@ -583,6 +593,8 @@ impl<R: Runtime> FileDialogBuilder<R> {
583593
/// This is not a blocking operation,
584594
/// and should be used when running on the main thread to avoid deadlocks with the event loop.
585595
///
596+
/// See [`Self::blocking_save_file`] for a blocking version for use in other contexts.
597+
///
586598
/// # Examples
587599
///
588600
/// ```
@@ -604,8 +616,11 @@ impl<R: Runtime> FileDialogBuilder<R> {
604616
/// Blocking APIs.
605617
impl<R: Runtime> FileDialogBuilder<R> {
606618
/// Shows the dialog to select a single file.
619+
///
607620
/// This is a blocking operation,
608-
/// and should *NOT* be used when running on the main thread context.
621+
/// and should *NOT* be used when running on the main thread.
622+
///
623+
/// See [`Self::pick_file`] for a non-blocking version for use in main-thread contexts.
609624
///
610625
/// # Examples
611626
///
@@ -623,8 +638,11 @@ impl<R: Runtime> FileDialogBuilder<R> {
623638
}
624639

625640
/// Shows the dialog to select multiple files.
641+
///
626642
/// This is a blocking operation,
627-
/// and should *NOT* be used when running on the main thread context.
643+
/// and should *NOT* be used when running on the main thread.
644+
///
645+
/// See [`Self::pick_files`] for a non-blocking version for use in main-thread contexts.
628646
///
629647
/// # Examples
630648
///
@@ -642,8 +660,11 @@ impl<R: Runtime> FileDialogBuilder<R> {
642660
}
643661

644662
/// Shows the dialog to select a single folder.
663+
///
645664
/// This is a blocking operation,
646-
/// and should *NOT* be used when running on the main thread context.
665+
/// and should *NOT* be used when running on the main thread.
666+
///
667+
/// See [`Self::pick_folder`] for a non-blocking version for use in main-thread contexts.
647668
///
648669
/// # Examples
649670
///
@@ -662,8 +683,11 @@ impl<R: Runtime> FileDialogBuilder<R> {
662683
}
663684

664685
/// Shows the dialog to select multiple folders.
686+
///
665687
/// This is a blocking operation,
666-
/// and should *NOT* be used when running on the main thread context.
688+
/// and should *NOT* be used when running on the main thread.
689+
///
690+
/// See [`Self::pick_folders`] for a non-blocking version for use in main-thread contexts.
667691
///
668692
/// # Examples
669693
///
@@ -682,8 +706,11 @@ impl<R: Runtime> FileDialogBuilder<R> {
682706
}
683707

684708
/// Shows the dialog to save a file.
709+
///
685710
/// This is a blocking operation,
686-
/// and should *NOT* be used when running on the main thread context.
711+
/// and should *NOT* be used when running on the main thread.
712+
///
713+
/// See [`Self::save_file`] for a non-blocking version for use in main-thread contexts.
687714
///
688715
/// # Examples
689716
///

0 commit comments

Comments
 (0)