Optimized copy-able types
This commit is contained in:
@@ -24,7 +24,7 @@ pub(super) fn draw_add_movie_search_popup<B: Backend>(
|
||||
app: &mut App,
|
||||
area: Rect,
|
||||
) {
|
||||
if let Route::Radarr(active_radarr_block) = app.get_current_route().clone() {
|
||||
if let Route::Radarr(active_radarr_block) = *app.get_current_route() {
|
||||
match active_radarr_block {
|
||||
ActiveRadarrBlock::AddMovieSearchInput | ActiveRadarrBlock::AddMovieSearchResults => {
|
||||
draw_add_movie_search(f, app, area);
|
||||
@@ -66,7 +66,7 @@ fn draw_add_movie_search<B: Backend>(f: &mut Frame<'_, B>, app: &mut App, area:
|
||||
.style(style_default())
|
||||
.block(title_block_centered("Add Movie"));
|
||||
|
||||
if let Route::Radarr(active_radarr_block) = app.get_current_route().clone() {
|
||||
if let Route::Radarr(active_radarr_block) = *app.get_current_route() {
|
||||
match active_radarr_block {
|
||||
ActiveRadarrBlock::AddMovieSearchInput => {
|
||||
show_cursor(f, chunks[0], block_content);
|
||||
@@ -169,7 +169,7 @@ fn draw_add_movie_search<B: Backend>(f: &mut Frame<'_, B>, app: &mut App, area:
|
||||
}
|
||||
|
||||
fn draw_confirmation_popup<B: Backend>(f: &mut Frame<'_, B>, app: &mut App, prompt_area: Rect) {
|
||||
if let Route::Radarr(active_radarr_block) = app.get_current_route().clone() {
|
||||
if let Route::Radarr(active_radarr_block) = *app.get_current_route() {
|
||||
match active_radarr_block {
|
||||
ActiveRadarrBlock::AddMovieSelectMonitor => {
|
||||
draw_drop_down_popup(
|
||||
|
||||
@@ -36,7 +36,7 @@ mod movie_details_ui;
|
||||
pub(super) fn draw_radarr_ui<B: Backend>(f: &mut Frame<'_, B>, app: &mut App, area: Rect) {
|
||||
let (content_rect, _) = draw_tabs(f, area, "Movies", &app.data.radarr_data.main_tabs);
|
||||
|
||||
if let Route::Radarr(active_radarr_block) = app.get_current_route().clone() {
|
||||
if let Route::Radarr(active_radarr_block) = *app.get_current_route() {
|
||||
match active_radarr_block {
|
||||
ActiveRadarrBlock::Movies => draw_library(f, app, content_rect),
|
||||
ActiveRadarrBlock::SearchMovie | ActiveRadarrBlock::FilterMovies => {
|
||||
|
||||
@@ -349,7 +349,7 @@ fn draw_movie_releases<B: Backend>(f: &mut Frame<'_, B>, app: &mut App, content_
|
||||
.movie_releases
|
||||
.current_selection_clone()
|
||||
};
|
||||
let current_route = app.get_current_route().clone();
|
||||
let current_route = *app.get_current_route();
|
||||
|
||||
draw_table(
|
||||
f,
|
||||
|
||||
Reference in New Issue
Block a user