             NSMidY(titleView.bounds) - (segmentSize.height / 2.0),
             segmentSize.width, segmentSize.height)
         let segment = NSSegmentedControl(frame: segmentFrame)
-        segment.segmentCount = 3
-        segment.setLabel("车票预订", forSegment: 0)
-        segment.setLabel("抢票任务", forSegment: 1)
-        segment.setLabel("订单查询", forSegment: 2)
+        segment.segmentCount = 2
+        segment.setLabel(TrainBook, forSegment: 0)
+        segment.setLabel(TrainOrder, forSegment: 1)
+//        segment.setLabel(TainTask, forSegment: 2)
         segment.selectedSegment = 0
         segment.segmentStyle = NSSegmentStyle.TexturedSquare
         segment.target = self

    }
    
    func segmentTab(sender: NSSegmentedControl){
        selectModule(sender.selectedSegment)
    }
    
    func selectModule(moduleIndex:Int){
        if(moduleIndex == 2){
            if orderQueryViewController == nil{
                orderQueryViewController = OrderViewController()
            }
            self.window?.contentView = orderQueryViewController!.view
        }
        else if(moduleIndex == 0){
            if ticketQueryViewController == nil{
                ticketQueryViewController = TicketQueryViewController()
            }

    var taskViewController:TaskViewController?
    
    var loginWindowController:LoginWindowController!
    
    let TrainBook = "车票预订"
    let TrainTask = "抢票任务"
    let TrainOrder = "订单查询"
    
    override func windowDidLoad()
    {
