Пример #1
0
 private void ActionSelected(Base sender, ItemSelectedEventArgs arguments)
 {
     if (arguments.SelectedItem == null || arguments.SelectedItem.Name.Equals("Placeholder"))
     {
         return;
     }
     switch (arguments.SelectedItem.Name)
     {
     case "Blip":
         Function.LogDebug("ActionSelected Blip Vehicle");
         ComputerVehicleController.BlipVehicle(Vehicle, System.Drawing.Color.Yellow);
         break;
     }
 }
        private void OnQuickAction(object sender, QuickActions action)
        {
            switch (action)
            {
            case QuickActions.BLIP_VEHICLE:
                Function.LogDebug("ActionSelected Blip Vehicle");
                ComputerVehicleController.BlipVehicle(Vehicle, System.Drawing.Color.Yellow);
                break;

            case QuickActions.CREATE_TRAFFIC_CITATION:
                ComputerReportsController.ShowTrafficCitationCreate(null, DetailedEntity.Entity);
                break;

            case QuickActions.CREATE_ARREST_REPORT_FOR_DRIVER:
                ComputerReportsController.ShowArrestReportCreate(DetailedEntity.Entity, null);
                break;
            }
        }
        private void VehicleViewQuickActionSelected(object sender, ComputerVehicleDetails.QuickActions action)
        {
            switch (action)
            {
            case ComputerVehicleDetails.QuickActions.BLIP_VEHICLE:
            {
                ComputerVehicleController.BlipVehicle(DetailedEntity.Entity.Vehicle, System.Drawing.Color.Yellow);
                return;
            }

            case ComputerVehicleDetails.QuickActions.CREATE_TRAFFIC_CITATION:
            {
                ComputerReportsController.ShowTrafficCitationCreate(Globals.PendingTrafficCitation, DetailedEntity.Entity, PedCreateTrafficCitationActions);
                return;
            }

            case ComputerVehicleDetails.QuickActions.CREATE_ARREST_REPORT_FOR_DRIVER:
            {
                ComputerReportsController.ShowArrestReportCreate(DetailedEntity.Entity, PedCreateArrestReportActions);
                return;
            }
            }
        }