Skip to content

manager 和页面解耦合 #1

@Huang-Libo

Description

@Huang-Libo

目前 HLBFocusedWithDialogManagerHLBFocusedWithDialogViewController 是强耦合的,其实可以把 manager 写的更通用,使其能承载各种自定义的引导页面。实施方法:

  • HLBFocusedWithDialogManager 重命名为 HLBGuideManager
  • 内部的 -addFocusedWithDialogVC: 方法改为 -addGuideViewController:,并接受 UIViewController 类型的参数;
  • manager 内部使用的 HLBFocusedWithDialogViewController 类型全改为 UIViewController 类型。

这样,HLBFocusedWithDialogViewController 就只作为一种引导页类型出现。以后,可以不断地往本库中添加各种类型的引导页面以满足不同的需求。

如果已有的引导页类型无法满足需求,用户也可以很方便地新建自定义的引导页面,并交由 HLBGuideManager 管理。

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions