Skip to content

Commit

Permalink
refactor(composables): ♻️ add handling logic for objects not picked up
Browse files Browse the repository at this point in the history
  • Loading branch information
zouyaoji committed Dec 27, 2023
1 parent ab13e6d commit c457b21
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions packages/composables/use-drawing/use-drawing-fab.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/*
* @Author: zouyaoji@https://github.com/zouyaoji
* @Date: 2021-10-13 09:45:59
* @LastEditTime: 2023-03-13 17:52:59
* @LastEditTime: 2023-12-06 00:13:43
* @LastEditors: zouyaoji 370681295@qq.com
* @Description:
* @FilePath: \vue-cesium@next\packages\composables\use-drawing\use-drawing-fab.ts
* @FilePath: \vue-cesium\packages\composables\use-drawing\use-drawing-fab.ts
*/
import { VcCollectionPrimitive } from '@vue-cesium/components/primitive-collections'
import type { VcFabProps, VcFabRef } from '@vue-cesium/components/ui'
Expand Down Expand Up @@ -169,6 +169,11 @@ export default function (
return Cartesian3.clone(position, result)
}
}
} else {
position = scene.pickPosition(windowPosition, cartesianScratch)
if (defined(position)) {
return Cartesian3.clone(position, result)
}
}
}
if (defined(scene.globe)) {
Expand Down

0 comments on commit c457b21

Please sign in to comment.