clean code

This commit is contained in:
pengfei.zhou 2019-11-20 09:43:11 +08:00
parent 412b65c864
commit 9113f58106
2 changed files with 0 additions and 32 deletions

View File

@ -1,5 +1,4 @@
import { Group, Panel, List, text, gravity, Color, Stack, LayoutSpec, list, NativeCall, listItem, log, vlayout, Gravity, hlayout, Text } from "doric"; import { Group, Panel, List, text, gravity, Color, Stack, LayoutSpec, list, NativeCall, listItem, log, vlayout, Gravity, hlayout, Text } from "doric";
import { O_TRUNC } from "constants";
const colors = [ const colors = [
"#f0932b", "#f0932b",
"#eb4d4b", "#eb4d4b",

View File

@ -13,37 +13,6 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// import { View, Stack, VLayout, HLayout } from "../ui/view"
// export type ViewBlock = () => View
// export function stack(blocks: ViewBlock[]) {
// return takeAlso(new Stack)(
// it => {
// for (let block of blocks) {
// it.addChild(block())
// }
// })
// }
// export function vlayout(blocks: ViewBlock[]) {
// return takeAlso(new VLayout)(
// it => {
// for (let block of blocks) {
// it.addChild(block())
// }
// })
// }
// export function hlayout(blocks: ViewBlock[]) {
// return takeAlso(new HLayout)(
// it => {
// for (let block of blocks) {
// it.addChild(block())
// }
// })
// }
export function take<T>(target: T) { export function take<T>(target: T) {
return (block: (p: T) => void) => { return (block: (p: T) => void) => {
block(target) block(target)