فهرست منبع

MediaViewController: Initialize sortbutton

Sortbutton was not showing after editing
Carola Nitz 6 سال پیش
والد
کامیت
d59a653dbb
1فایلهای تغییر یافته به همراه5 افزوده شده و 4 حذف شده
  1. 5 4
      Sources/MediaViewControllers/MediaViewController.swift

+ 5 - 4
Sources/MediaViewControllers/MediaViewController.swift

@@ -40,10 +40,11 @@ class VLCMediaViewController: VLCPagingViewController<VLCLabelCell> {
         }
         navigationController?.navigationBar.isTranslucent = false
         navigationItem.rightBarButtonItems = [editButtonItem, UIBarButtonItem(customView: rendererButton)]
-        navigationItem.leftBarButtonItem = UIBarButtonItem(title: NSLocalizedString("SORT", comment: ""),
-                                                           style: .plain,
-                                                           target: self,
-                                                           action: #selector(handleSort))
+        sortButton = UIBarButtonItem(title: NSLocalizedString("SORT", comment: ""),
+                                     style: .plain,
+                                     target: self,
+                                     action: #selector(handleSort))
+        navigationItem.leftBarButtonItem = sortButton
     }
 
     // MARK: - PagerTabStripDataSource