Move Reader button to Safari button position on Article View. Issue #1260

This commit is contained in:
Maurice Parker 2019-11-06 08:00:20 -06:00
parent f96d4cbf17
commit 4f1e1ef0c2
2 changed files with 1 additions and 15 deletions

View File

@ -33,7 +33,6 @@ class ArticleViewController: UIViewController {
@IBOutlet private weak var readBarButtonItem: UIBarButtonItem!
@IBOutlet private weak var starBarButtonItem: UIBarButtonItem!
@IBOutlet private weak var actionBarButtonItem: UIBarButtonItem!
@IBOutlet private weak var browserBarButtonItem: UIBarButtonItem!
@IBOutlet private weak var webViewContainer: UIView!
private var articleExtractorButton: ArticleExtractorButton = {
@ -103,7 +102,7 @@ class ArticleViewController: UIViewController {
NotificationCenter.default.addObserver(self, selector: #selector(willEnterForeground(_:)), name: UIApplication.willEnterForegroundNotification, object: nil)
articleExtractorButton.addTarget(self, action: #selector(toggleArticleExtractor(_:)), for: .touchUpInside)
navigationItem.titleView = articleExtractorButton
toolbarItems?.append(UIBarButtonItem(customView: articleExtractorButton))
ArticleViewControllerWebViewProvider.shared.dequeueWebView() { webView in
@ -133,7 +132,6 @@ class ArticleViewController: UIViewController {
nextArticleBarButtonItem.isEnabled = false
readBarButtonItem.isEnabled = false
starBarButtonItem.isEnabled = false
browserBarButtonItem.isEnabled = false
actionBarButtonItem.isEnabled = false
return
}
@ -145,7 +143,6 @@ class ArticleViewController: UIViewController {
articleExtractorButton.isEnabled = true
readBarButtonItem.isEnabled = true
starBarButtonItem.isEnabled = true
browserBarButtonItem.isEnabled = true
actionBarButtonItem.isEnabled = true
let readImage = article.status.read ? AppAssets.circleOpenImage : AppAssets.circleClosedImage

View File

@ -69,15 +69,6 @@
</connections>
</barButtonItem>
<barButtonItem style="plain" systemItem="flexibleSpace" id="KUq-GZ-WY9"/>
<barButtonItem title="Safari" image="safari" catalog="system" id="DMh-3X-ebd">
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="boolean" keyPath="accEnabled" value="YES"/>
<userDefinedRuntimeAttribute type="string" keyPath="accLabelText" value="Safari"/>
</userDefinedRuntimeAttributes>
<connections>
<action selector="openBrowser:" destination="JEX-9P-axG" id="R0r-fI-NI7"/>
</connections>
</barButtonItem>
</toolbarItems>
<navigationItem key="navigationItem" largeTitleDisplayMode="never" id="mOI-FS-AaM">
<rightBarButtonItems>
@ -105,7 +96,6 @@
<simulatedToolbarMetrics key="simulatedBottomBarMetrics"/>
<connections>
<outlet property="actionBarButtonItem" destination="9Ut-5B-JKP" id="9bO-kz-cTz"/>
<outlet property="browserBarButtonItem" destination="DMh-3X-ebd" id="PkT-Tn-8kG"/>
<outlet property="nextArticleBarButtonItem" destination="2qz-M5-Yhk" id="IQd-jx-qEr"/>
<outlet property="nextUnreadBarButtonItem" destination="2w5-e9-C2V" id="xJr-5y-p1N"/>
<outlet property="prevArticleBarButtonItem" destination="v4j-fq-23N" id="Gny-Oh-cQa"/>
@ -278,7 +268,6 @@
<image name="circle" catalog="system" width="64" height="60"/>
<image name="gear" catalog="system" width="64" height="58"/>
<image name="multiply.circle.fill" catalog="system" width="64" height="60"/>
<image name="safari" catalog="system" width="64" height="60"/>
<image name="square.and.arrow.up" catalog="system" width="56" height="64"/>
<image name="square.and.arrow.up.fill" catalog="system" width="56" height="64"/>
<image name="star" catalog="system" width="64" height="58"/>